These forums are locked and archived, but all topics have been migrated to the new forum. You can search for this topic on the new forum: Search for Error php it download instead of executing on the new forum.
Hello i try to search my problem before posting but no luck!
I got file download while access my website instead of executing. The apache configuration below
SuexecUserGroup "#1004" "#1004"
ServerName ***.cf
ServerAlias www.***.cf
ServerAlias webmail.****.cf
ServerAlias admin.***.cf
DocumentRoot /home/****/public_html
ErrorLog /var/log/virtualmin/****_error_log
CustomLog /var/log/virtualmin/***_access_log combined
ScriptAlias /cgi-bin/ /home/****/cgi-bin/
ScriptAlias /awstats/ /home/****/cgi-bin/
DirectoryIndex index.html index.htm index.php index.php4 index.php5
<Directory /home/****/public_html>
Options -Indexes +IncludesNOEXEC +SymLinksIfOwnerMatch +ExecCGI
allow from all
AllowOverride All Options=ExecCGI,Includes,IncludesNOEXEC,Indexes,MultiViews,SymLinksIfOwnerMatch
Require all granted
AddType application/x-httpd-php .php
AddHandler fcgid-script .php
AddHandler fcgid-script .php5
AddHandler fcgid-script .php5.5
FCGIWrapper /home/****/fcgi-bin/php5.fcgi .php
FCGIWrapper /home/****/fcgi-bin/php5.fcgi .php5
FCGIWrapper /home/****/fcgi-bin/php5.5.fcgi .php5.5
</Directory>
<Directory /home/****/cgi-bin>
allow from all
AllowOverride All Options=ExecCGI,Includes,IncludesNOEXEC,Indexes,MultiViews,SymLinksIfOwnerMatch
Require all granted
</Directory>
RewriteEngine on
RewriteCond %{HTTP_HOST} =webmail.****
RewriteRule ^(.*) https://*****:20000/ [R]
RewriteCond %{HTTP_HOST} =admin.****
RewriteRule ^(.*) https://****:10000/ [R]
RemoveHandler .php
RemoveHandler .php5
RemoveHandler .php5.5
php_admin_value engine Off
FcgidMaxRequestLen 1073741824
SSLEngine on
SSLCertificateFile /home/****/ssl.pem
SSLCertificateKeyFile /home/****/ssl.key
<Files awstats.pl>
AuthName "**** statistics"
AuthType Basic
AuthUserFile /home/****/.awstats-htpasswd
require valid-user
</Files>
IPCCommTimeout 31
php_value memory_limit 32M
Howdy,
What distro/version is it that you're using there?
And it looks like you have multiple PHP versions available on your server, which PHP version is it that's experiencing this issue?
-Eric
that could be error in php file it self.. if its badly coded then it can give you white page or download the file it self - perhaps if php file is legit and good then you may need to install php-modules...
Configuring/troubleshooting Debian servers is always great fun
Create new file "testphp.php" under the domain where you are experiencing the problem and fill with:
<html>
<head>
<title>PHP Test</title>
</head>
<body>
<?php echo '<p>Hello World</p>'; ?>
</body>
</html>
Once done try to load the page with "http(s)://your_domain.tld/testphp.php". If you can load the file means your php code is broken, in case the problem is still present then probably you should start looking at Apache configuration.
- I often come to the conclusion that my brain has too many tabs open. -
Failing at desktop publishing & graphic design since 1994.
Hello everyone i'm sorry for bumping the forum. Please close this post or delete it because i'm reinstall a new fresh system. Because i can't wait. I'm sorry for that. Now everything working fine thank you!