How to have multiple php version in one machine

Our net administrator currently has php 4.1.2 installed. I want to add some contents which require php 4.3+ version. Provide our administrator cannot upgrade for me, how can I have two php version installed in the same machine ***without*** bringing any negative effects to existed websites (they work properly in php 4.1.2).

Our admin told me the include_path of our php.ini is:

include_path = ".;f:\php42\includes;f:\php42\pear"

and php.ini is in C:\WINNT\system32\.

Thanks!
LVL 1
tiger0516Asked:
Who is Participating?
 
tdterryCommented:
I think you'll need some help from your admin on this, but you can install PHP 4.3 in a separate folder, and use CGI invocation.  Also, the setup depends on your web server, which you didn't specify.

Install PHP 4.3 in f:\php43
In f:\php43\php.ini, set your include path to ".;f:\php42\includes;f:\php43\pear", etc
Configure the web server's virtual host for your domain name to run .PHP files as CGI scripts using f:\php43\php.exe

If you aren't using virtual hosts, then you'll have to name your scripts something else (like .PHP43), and use CGI based on that extension.  I don't recommend this as you will have a hard time hosting on other servers, which surely won't know about the .PHP43 extension.

Travis
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.