Windows Server 2008 IIS 7 running php configuration method

  
                  

This article talks about how to add support for PHP pages in Vista/Windows Server 2008 under IIS7. The efficiency of running PHP in Windows Server 2008 has increased by more than 40%.

System Environment: Vista /Windows Server 2008

First, install IIS7 (Control Panel\\Programs and Features, Windows Features). Under the default selection conditions, remember to check ISAPI. Two options.

After the installation is complete, enter http://127.0.0.1 in the browser. If nothing happens, an IIS7 welcome screen will appear.

Second, next, install PHP

Download the PHP installation package to: http://cn.php.net/downloads.php, download windows binaries here. After completing the PHP installation, I installed it in d:\\php. In this directory, I found php.ini-dist, renamed it to php.ini, opened php.ini:

Found:extension_dir = "./", replaced with extension_dir = "d:\\php";

Found: Windows Extensions:

Remove the comment for each line in the module configuration below, for example:

extension=php_mbstring.dll

extension=php_gd2.dll

extension=php_MySQL.dll

Save. Copy the file to your system's windows directory.

Third, create a new application pool in IIS7, the pool's .Net type is set to unmanaged.

Create a new website, open the "Read" and "Run Script" permissions, after completion, add ISAPI Filters

to this site and then add Handler Mapping

In the process, add D:\\PHP\\php5isapi.dll to Handler Mapping

OK, and all operations are completed. Now you can test if a PHP file is working properly.

Copyright © Windows knowledge All Rights Reserved