wisinc99 Posted August 28, 2008 Share Posted August 28, 2008 Web Host just moved me to a new server and upgraded from PHP4 to PHP5 the server is Apache now, a simple thing like <?php echo '<p>Hello World</p>'; ?> does not work from within an 'html' document (ie php_basic.html) I have to rename to a 'php' document (ie php_basic.php) then it works. I'm going to have to change menus and filenames throughout several websites. The web host says they have no idea, but security is much tighter (?) Does anyone have an idea how to get around this? Quote Link to comment Share on other sites More sharing options...
trq Posted August 28, 2008 Share Posted August 28, 2008 Add the following line into your .htaccess file. AddType x-httpd-php .php .html Quote Link to comment Share on other sites More sharing options...
wisinc99 Posted August 28, 2008 Author Share Posted August 28, 2008 I did that but no that didn't help .htaccess follows: # -FrontPage- IndexIgnore .htaccess */.??* *~ *# */HEADER* */README* */_vti* AddType x-httpd-php .php .html <Limit GET POST> order deny,allow deny from all allow from all </Limit> <Limit PUT DELETE> order deny,allow deny from all </Limit> (I removed 3 Auth entries from this post) Actual page is at http://www.palmettomachine.com/new/php_basic.html Quote Link to comment Share on other sites More sharing options...
DarkWater Posted August 29, 2008 Share Posted August 29, 2008 PHP isn't SUPPOSED to work with in an HTML document unless you have the MIME types set up properly, but thorpe's line should have fixed that... >_> Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.