Install PHP5 on Windows XP Manually
This post will explain how to setup PHP5 to run from your computer. It will not cover all-in-one packages which install php, apache and mysql with default settings. If you find it usefull, please bookmark this page for later reference.
PHP5 INSTALLATION
Go to http://www.php.net/downloads.php and donwload latest php5 binary (zip package).
Extract zip package in to D:\webserver\php5 (you can choose another location on your computer but it is better to have everything installed in one place).
Copy libmysql.dll and php5ts.dll to C:\WINDOWS\system32 folder
Find a file called php.ini-dist and make a copy of it. Rename that copy file to php.ini and move into C:\WINDOWS folder.
Go to C:\WINDOWS and find the file php.ini you’ve just moved here. Open it with notepad. Php.ini is a configuration file for php5.
Press ctrl+f and type extension_dir to find the line with that phrase. Change “./” with “D:\webserver\php5\ext” (change path according to your own settings if needed) This tells php where to find various extensions which can provide functionality. One of these extensions allows php to communicate with mysql databases.
Scroll down the php.ini file until you see a long list of extensions. Notice that semicolumns mean that this extension is disabled. To enable extensions in php you have to remove semicolumns on that line. To enable mysql delete semicolumn on the line “;extension=php_mysql.dll”. Do the same for line “;extension=php_mysqli.dll”
Scroll down until line ;session.save_path = “/tmp” and delete semicolumn (” ; “) Then instead “/tmp” write D:\webserver\php5\temp This tells php where to store temporary files. You can type here any folder you want. Save the file.
You have succesfully installed PHP5 on your computer. Now it’s time to install apache and configure it to use php5.
August 17th, 2008 at 9:20 am
[…] Install PHP5 on Windows XP Manually […]