Portal Home > Knowledgebase > Articles Database > php 4/5 and apache 2?


php 4/5 and apache 2?




Posted by Calibaba, 03-08-2008, 08:19 PM
I would like to compile apache 2.2 with php 4.4.8 and fastcgi, plus phpsuexec support. Is this a stable option or not? I would also like to do the same, but with php 5 as well simultaneously on another server. My question is how would a clients script know what to use, php4 or php5 on the same box? Also, when is MPM Prefork recommended? Last edited by Calibaba; 03-08-2008 at 08:23 PM.

Posted by deseek, 03-08-2008, 08:47 PM
Having php 4 and 5 installed will work fine. I can give you a rough idea but there is alot of extensive documentation on exactly how to do such a setup if you google it. When you have everything installed, you edit your apache2.conf file and add index.php4 to DirectoryIndex That will let apache recognize index.php4 files as an index file. You would also add this where you will see other entries that look similar to run php4 files as cgi AddHandler php-script .php4 Action php-script /cgi-bin/php4 and then enable whatever modules you need basically, files with the file extension .php4 will be ran as cgi, where as .php extensions would be run by the apache php5 module. Hope that gives you an idea.



Was this answer helpful?

Add to Favourites Add to Favourites    Print this Article Print this Article

Also Read
upgrade phpgadmin (Views: 828)
ionCube upgrade (Views: 2097)
rsync / backup (Views: 603)