To assign a particular PHP version to a site, use the following commands. Configuring FastCGI on a server level and switching between PHP versions is exactly the same procedure as for IIS 5.1.Īdditionally FastCGI can be configured on a site level, which would allow using of different PHP versions for different web sites. IIS 6.0įastCGI on IIS 6.0 can be configured on a server level, which would cause all the IIS web sites to use the same PHP version. FastCGI Extension will pick up the changes as soon as file has been saved. There is no need to restart IIS after the updates to fcgiexe.ini have been made.
#Iis web server extensions update#
To switch back to PHP 5.2.11 update the section by commenting out php=php531 and un-commenting php=php5211.
![iis web server extensions iis web server extensions](https://www.howtogeek.com/wp-content/uploads/sg/2010/03/image3_thumb.png)
To switch to PHP 5.3.1, just add another section declaration and then modify the section as below: This configures IIS to use PHP 5.2.11 whenever a request for a *.php file is made. At the end of the file there will be a section that defines FastCGI applications. Open the IIS FastCGI extension configuration file at %windir%\system32\inetsrv\fcgiext.ini. But it is possible to have a configuration that allows to easily switch from one version to another. Since IIS 5.1 can have only one web site, it is not possible to configure it to have two versions of PHP running at the same time. The FastCGI Extension can be configured on a server and a site level. PHP 5.2.11 files are located in C:\PHP5211\ directory and PHP 5.3.1 files are located in C:\PHP531\ directory. Note: in all examples below two PHP versions are installed on the same server.
![iis web server extensions iis web server extensions](https://cdn.comparitech.com/wp-content/uploads/2018/09/Microsoft-IIS-screenshot-.jpg)
After that proceed to configuring an IIS server as per instructions below: Do not use PHP Windows installer because it does not support side by side installations.Īfter a particular version of PHP has been installed in accordance to the instructions, download another version of PHP, extract it into a separate directory and configure it in accordance to Manual Installation Steps.
#Iis web server extensions install#
In order to setup multiple versions of PHP side by side on the same IIS server it is necessary to install PHP manually by following the steps described in php.net documentation for IIS 5.1 and IIS 6.0 and for IIS 7.0 and later. Also, it is often used in production environments, where many PHP applications are hosted on the same server and some of them have dependency on a particular PHP version. This kind of setup is useful in development environments where it is necessary to test an application with different PHP versions. This post describes how to configure IIS to support multiple versions of PHP on the same server.