Hey I hope someone can help: I've got a problem where PHP does not parse in one particular directory. Instead I see the download file dialog for index.php, and for index.html which has some php code in it, it displays the code instead of executing it. I've checked and phpinfo works fine in the root, and in other directories on the same server/domain. This one directory has its own .htaccess, but it was working previously, and stopped sometime in the last few days: AddDefaultCharset utf-8 AddHandler application/x-httpd-php .php .html .htm RewriteEngine on RewriteRule ^stats\.js$ stats.php I am not a PHP expert - can anyone shed some light on this behavior? I havent found anything on google that talks about PHP not parsing in one directory only. Thanks,, JK
But I need that line because I have some php code inside a .html file. It will not be parsed without that line. It was working and parsing correctly, but it just stopped. I have confirmed that it is probably the .htaccess. I created a new directory with just phpinfo in it, and it worked. I added the .htaccess and it stopped working. I still dont know how to fix it however JK
I believe when running PHP as CGI you use AddHandler. When using PHP as a module AddType is used. Just for fun try replacing with this. You can always change it back. AddType application/x-httpd-php .php .html .htm