Apache Lounge



Forum Index Downloads Search Register Log in  RSS Apache Lounge

Keep Server Online

If you find the Apache Lounge, the downloads and overall help useful, please express your satisfaction with a donation.



A donation makes a contribution towards the costs, the time and effort that's going in this site and building.

Thank You! Steffen

Apache Lounge is not sponsored.

Your donations will help to keep this site alive and well, and continuing building binaries.

BitNami WAMP Stack

Contains ApacheLounge build

running PHP 4 and PHP 5 at the same time

Post new topic   Reply to topic    Apache Forum Index -> Other Software

View previous topic :: View next topic  
Author Message

Joined: 15 Dec 2005
Posts: 36

PostPosted: Thu 27 Apr '06 18:18    Post subject: running PHP 4 and PHP 5 at the same time Reply with quote

Good day to all, just have a question, ive read that php 4 and php 5 can be added to the httpd to allow use of both, i have both installed on my webserver, and both are working, need to know how to add them to the httpd so i can use them, almost all of my website runs fine with php 4 x's but i have some newer scripts that require php 5 ( id rather just use php 5, But the phpbb install isnt liking it, and doesnt show all of the admin panel and registrations fail) if anyone can help, or show an example on how to add both life would get much easier around here.

Back to top

Joined: 15 Oct 2005
Posts: 2628
Location: Hilversum, NL, EU

PostPosted: Thu 27 Apr '06 18:29    Post subject: Reply with quote

You need an extra extension, eg php4.


LoadFile "c:/php/php4ts.dll"
LoadModule php4_module "c:/php/php4apache2.dll"
PHPINIDir x:/xxxx/xxx
AddType application/x-httpd-php4 .php4

I tried once php5 as apaceh handler and php4 as cgi (extension .phpc), and that was working fine:

#ScriptAlias /phpc/ "D:/servers/apache/phpc/"
#AddType application/x-httpd-phpc .phpc
#Action application/x-httpd-phpc "/phpc/php-cgi.exe"
#SetEnv PHPRC D:/servers/apache/phpc

Back to top

Joined: 15 Dec 2005
Posts: 36

PostPosted: Mon 08 May '06 2:58    Post subject: thnx Reply with quote

works like a charm, thnx
Back to top

Joined: 10 May 2006
Posts: 7

PostPosted: Thu 11 May '06 18:48    Post subject: Reply with quote

if you do it like this, don't both versions of php have to use the same php.ini?
Back to top
James Blond

Joined: 19 Jan 2006
Posts: 6317
Location: Germany, Next to Hamburg

PostPosted: Thu 11 May '06 19:32    Post subject: Reply with quote

yepp, if you comment some settings out, so PHP will use default settings and will work for PHP 4 and 5.
Back to top

Post new topic   Reply to topic    Apache Forum Index -> Other Software
Page 1 of 1