cluce Posted August 13, 2007 Share Posted August 13, 2007 If I just did phpinfo(); and phpinfo('cgi'); and they both show php 4 info pages. Does this GUARANTEE me that the web hosting company hosting our web pages is running php 4?? He says he is running 4 and 5 but I am starting to disagree. Quote Link to comment Share on other sites More sharing options...
akitchin Posted August 13, 2007 Share Posted August 13, 2007 i believe for hosts that offer 4 AND 5, you need to change the extension of one or the other (usually 5) to invoke the version parser of your choice. try renaming your phpinfo file to .php5 and see what it says then. Quote Link to comment Share on other sites More sharing options...
cluce Posted August 13, 2007 Author Share Posted August 13, 2007 thanks ...........that pulled up the php 5 info. so I just figured out I need to rename my php extensionsions to .php5 for it to work on the web server in production but for my local machine for testing I need it to be .php for it to run. Can I fix this anyway? Or what would be the easist wat you can recommend? Quote Link to comment Share on other sites More sharing options...
akitchin Posted August 13, 2007 Share Posted August 13, 2007 there's an apache setting in the httpd.conf file that tells the server what extensions to look for and what to parse them with. if you add .php5 to the mix in your local server, you can keep all files named .php5 and have them test the same (assuming the same PHP5 versions are running), be they local or host-run. unfortunately you're stuck with that setting on your host, unless you buy a VPS. Quote Link to comment Share on other sites More sharing options...
cluce Posted August 13, 2007 Author Share Posted August 13, 2007 there's an apache setting in the httpd.conf file that tells the server what extensions to look for and what to parse them with. if you add .php5 to the mix in your local server, you can keep all files named .php5 and have them test the same (assuming the same PHP5 versions are running), be they local or host-run. unfortunately you're stuck with that setting on your host, unless you buy a VPS. yeah, I figured I would have to make some changes to my server is this where I would add the .php5 ..... AddType text/html .php .phps .php5 AddHandler application/x-httpd-php .php .php5 Quote Link to comment Share on other sites More sharing options...
akitchin Posted August 13, 2007 Share Posted August 13, 2007 looks like it - give it a whirl and see how it goes. don't forget to mark this solved once you're happy. 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.