Forum Moderators: coopster
I have added code:
AddType application/x-httpd-php .htm
to my htaccess file
and then attempted to run a web page
with the following code embedded in in:
<?php echo "I LOVE PHP!";?>
Yet when I try my www.mydomain.test1.htm page I get a blank page in IE
any help would be appreciated
Thanks
Not sure what u mean by the above
I placed:
<?php echo "I LOVE PHP!";?>
in the html source of a page called test1.htm yet see nothing when I visit the page www.mydomain.com/test1.htm
Viewed as source in browser
lost...yes, i am
>> www.mydomain.test1.htm page
your AddType line looks fine but obviously isn't quite right
I would probably suggest contacting your host to make sure you can use .htaccess files, hich I am guessing you can as they screwed eveything up.
Also make sure php is installed and that what you are trying should work.
Just doesn't work in a htm page with any
entry I have made to htaccess.
Yes, I am able to edit htaccess and changes
do take effect.
Thanks
also, yes that was a typo above
The first thing I would do is run phpinfo() and find out if mod_mime is loaded and accessible to you -- If not you will need to contact your host.
Second I would try a simple rewrite or something that I know works, to determine if AllowOverride is set to FileInfo or All.
Third, I would try using AddHandler, rather than type:
AddHandler application/x-httpd-php .htm
Hope this gives you some ideas.
Justin
Tried
AddHandler application/x-httpd-php .htm
blank page is the result
my other items in my htaccess seem to work fine:
RewriteEngine on
RewriteCond %{HTTP_HOST} .
RewriteCond %{HTTP_HOST}!^www\.mydomain\.com
RewriteRule (.*) [mydomain.com...] [R=301,L]
RewriteCond %{QUERY_STRING}!^$
RewriteRule .* - [G]
AddType text/html .shtml .shtm .htm .html
AddHandler server-parsed .shtml .shtm .htm .html
AddHandler application/x-httpd-php .htm
ran php info and didnt see anything about mod_mime so maybe thats the problem