Sunday, June 20, 2010

PHP Install - How to install PHP 5.2 and later

PHP Installation with Windows Installer for PHP 5.2 and later



The PHP installer for WINDOWS for version 5.2 and above has benn built using MSI technology using the Wix Toolkit.You can search for the source code on sourceforge. Using this PHP installer you can install and configure PHP and all the built-in PECL extensions,as well as configure many popular web servers such as IIS, Apache, and Xitami.



First, you need to install your selected HTTP Web server on your system, and make sure that it is working properly. Then proceed with one of the following install types.



Normal Installation Process



First run the MSI installer and follow the instructions provided by the installation wizard. You will be prompted to choose the Web Server you wish to configure first, along with any configuration details needed.



You will then be prompted to choose which features and extensions you wish to install and enable. By selecting "Will be installed on local hard drive" in the drop-down menu for each item you can trigger whether to install the feature or not. By selecting "Entire feature will be installed on local hard drive", you will be able to install all sub-features of the included feature ( for example by selecting this options for the feature "PDO" you will install all PDO Drivers ).



Warning regarding PHP Installation



It is not at all recommended to install all extensions by default, since many other them require dependencies from outside PHP in order to function properly. Instead, use the Installation Repair Mode that can be triggered thru the 'Add/Remove Programs' in the Control panel to enable or disable extensions and features after installation.



The installer then sets up PHP to be used in Windows and the php.ini file, and configures certain web servers to use PHP. The installer will currently configure IIS, Apache, Xitami, and Sambar Server; if you are using a different web server you'll need to configure it manually.



Silent Installation for PHP 5.2



The installer also supports a silent mode, which is helpful for Systems Administrators to deploy PHP easily. To use silent mode:




msiexec.exe /i php-VERSION-win32-install.msi /q



You can control the install directory by passing it as a parameter to the install. For example, to install to d:\php:




msiexec.exe /i php-VERSION-win32-install.msi /q INSTALLDIR=e:\php



You can also use the same syntax to specify the Apache Configuration Directory (APACHEDIR), the Sambar Server directory (SAMBARDIR), and the Xitami Server directory (XITAMIDIR).



You can also specify what features to install. For example, to install the mysqli extension and the CGI executable:




msiexec.exe /i php-VERSION-win32-install.msi /q ADDLOCAL=cgi,ext_php_mysqli



The current list of features to install it are as follows:




MainExecutable - php.exe executable ( no longer available as of PHP 5.2.10/5.3.0; it is now included by default )


ScriptExecutable - php-win.exe executable


ext_php_* - the various extensions ( for example: ext_php_mysql for MySQL )
apache13 - Apache 1.3 module
apache20 - Apache 2.0 module
apache22 - Apache 2,2 module
apacheCGI - Apache CGI executable
iis4ISAPI - IIS ISAPI module
iis4CGI - IIS CGI executable
iis4FastCGI - IIS CGI executable
NSAPI - Sun/iPlanet/Netscape server module
netserve - NetServe Web Server CGI executable
Xitami - Xitami CGI executable
Sambar - Sambar Server ISAPI module
CGI - php-cgi.exe executable
PEAR - PEAR installer
Manual - PHP Manual in CHM Format

For more information on installing MSI installers from the command line, visit » PHP MSI Installation.

Updating PHP 5.2 with the Complete Install



To upgrade, run the installer either graphically or from the command line as normal. The installer will read your current install options, remove your old installation, and reinstall PHP with the same options as before. It is recommended that you use this method of keeping PHP updated instead of manually replacing the files in the installation directory.



Read More about



The Prerequisites for PHP learning.



PHP Development and Design - The Complete Guide.




PHP Tutorials PHP Development and Design PHP Learning Prerequisites PHP Books PHP Install for Windows


No comments:

Post a Comment

PHP | PHP Books | PHP Tutorials | PHP Development