logo
Published on Technical articles on: Windows servers, Apache Web Server, MySQL, PHP, IIS (http://www.sitebuddy.com)

Apache: PHP Quick Shift Install

By chris
Created 16 Feb 2006 - 11:05pm
Once familiar with the install process, see: Apache: Install PHP
In order to quickly shift between PHP versions here is my setup.

1) In your "bin" folder create a phpXXX folder (with XXX being the PHP version).
Example: E:\apache2\bin\php442

2) Copy the following 17 files, from your PHP version, to your phpXXX folder:
expat.dll
FDFTK.DLL
fribidi.dll
gds32.dll
iconv.dll
libeay32.dll
libmhash.dll
libmysql.dll
msql.dll
ntwdblib.dll
php4ts.dll
phpsrvlt.dll
phpsrvlt.jar
sablot.dll
ssleay32.dll
Yaz.dll
php4apache2.dll (substitute with the appropriate DLL of your PHP version and/or Apache distribution)

3) Create a new folder that will contain the extensions of your PHP version.
Example: E:\apache2\php\ext442

4) Upload  the content of the extensions folder from your PHP version, to the folder created in step 3).
For example: Copy the content of
M:\Software\Dev\_php\PHP 4.4.2\php-4.4.2-Win32\extensions
to
E:\apache2\php\ext442
 

5) Now customize a php-apache2handler.ini for this version.
Basically customize the directive:
extension_dir = "E:/apache2/php/ext442"

Copy that file into your E:\apache2\bin\php442

6) Now when you want to run that version of PHP simply copy of the files in E:\apache2\bin\phpXXX to the E:\apache2\bin\ folder.
Make sure your httpd.conf contains the appropriate path:
LoadModule php4_module "E:/apache2/bin/php4apache2.dll"
 

 


Source URL:
http://www.sitebuddy.com/Apache/Windows/Install/PHP/Versions