Setting up your first web server on windows with Apache, PHP and MySQL
Published: August 5, 2003
User Rating: 9.1 (511 votes)
Unzip the php installation zip file to a directory such as
"D:\PHP". For this article we 'll assume that PHP is installed in
Make sure that while unzipping, you have selected the options to hierarchically create sub-folders. For e.g. "Use folder name" (in WinZip). This option 'll automatically create the subdirectory and put the respective files in them automatically.
After you have unzipped the files, Edit the
"php.ini"file. If the
php.inifile does't exists, then copy and rename the
php.inifile and find the
"extension_dir"entry and enter the absolute path of the directoryextension_dir="C:/PHP/extensions/"
make sure you enter the directory where you installed the PHP and take care of the slashes while entering. Save and close the file.
Enter the following command in the command prompt in the PHP directoryphp -v
If you see the the version of php printed without any errors. The PHP has been successfully installed.Warning:
php.inilook for line like having text like
c:\Program Files\Zend\ZendOpimizer.dllor linking to similar file. Make sure that the file exists in the exact same position. If not comment out the line by putting a ; (semi-colon) as the first character of the line.
Also, if you have enabled few extensions like
extension=php_xslt.dll, then these extensions require few files found in
iconv.dll, etc which are needed to be moved to the WINDOWS\System32 folder. You 'll find out when you check the version of php or start Apache (integrated with PHP).