IIS supports PHP

Source: Internet
Author: User
1. Decompress php-5.2.6.zip to D: php5, find php. ini-dist and change it to php. ini and put it in the C: WINDOWS directory. 2. Set libmcrypt under the D: php5 directory. dll and libmysql. dll and php5ts. dll to C: WINDOWSsystem32 (this is to make these three files can be called by IIS to facilitate loading the corresponding module) 3. Open W

1. Decompress php-5.2.6.zip to D: \ php5, find php. ini-dist and change it to php. ini and put it in the C: \ WINDOWS directory. 2. Set libmcrypt under the D: \ php5 directory. dll and libmysql. dll and php5ts. dll to C: \ WINDOWS \ system32 (this is to make these three files can be called by IIS to facilitate loading the corresponding module) 3. Open W

1. Decompress php-5.2.6.zip to D: \ php5, find php. ini-dist and change it to php. ini and put it in the C: \ WINDOWS directory.

2. Set libmcrypt under the D: \ php5 directory. dll and libmysql. dll and php5ts. dll to C: \ WINDOWS \ system32 (this is to make these three files be called by IIS to facilitate loading the corresponding modules)

3. Open php. ini in the WINDOWS directory,

Change display_errors = On to display_errors = Off (indicating no error information is displayed. It is best to set it in the launch environment so that the program error information is not displayed to the viewer)

Change extension_dir = "./" to extension_dir = "G:/php5/ext" (change the extension module path)

Find

; Extension = php_gd2.dll (this is used to support the GD library)

; Extension = php_mbstring.dll)

; Extension = php_mysql.dll (required to support MYSQL)

Remove ";" in front of the text. You can also remove the previous text if you need it. Then, close and save the file.

4. Open Control Panel → Administrative Tools → Internet Information Service (IIS) manager, expand local computer → website, right-click the default website, and select Properties.

5. Click the "ISAPI filter" tab, and then click "add". In the "filter attributes" dialog box that appears, enter the Filter Name "php" and the executable file "D: \ php5 \ php5isapi. dll "and click" OK "to exit.

6. Click the "handler ing" tab, click the "add script ing" button, and fill in the content as shown in:

7. Click the "document" tab to add index. php as the default homepage"

8. Click "application pool" and select "add application pool ":

9. Restart IIS and add the following file named "index. php" under the IIS root directory:

10. Open IE and enter "http: // localhost/or http: // 127.0.0.1/" in the address bar. The PHP configuration is successful, as shown in the following figure, if it fails, check whether the website directory permission and IIS permission are configured.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.