Forum Moderators: phranque
I'm trying to parse my .htm pages as .php. The server I'm on is running Apache 2 and PHP 4. I have several pages that have the .htm extension. Instead of changing the names, I wanted to just change the way the server is parsing these pages. After looking through the forums, it looks like if you add:
AddHandler application/x-httpd-php .htm .html
to the .htaccess you should be able to do just that.
I have tried that line (and many variations of that line), with no luck. I've tried placing "RemoveHandler htm html" in there as well, with no luck.
It seems as though I should be able to go into httpd.conf and check the settings, but I can't see the file on my file manager list. Could there be another file to look for? Is it possible my host does not allow access to this file?
I've emailed tech-support a couple of days ago with my problem, but they have not gotten back to me. What kind of things should I be asking my host to get my problem resolved?
Thanks
Jim
I went through about 50 combinations of:
-AddType application/x-httpd-php .htm .html .php
-AddHandler application/x-httpd-php .php .html
-AddType x-httpd-php .html .htm
-RemovHandlre .htm .html
-AddType x-mapp-php4 .html .htm .shtml
removeHandler server-parsed shtml
and plenty of other suggestions through-out the web, but I finally came across the one that worked for me:
AddHandler php-script .php .php4 .php3 .html .htm .phtml