iis+php (FastCGI)

Source: Internet
Author: User
Tags configuration php install php php website

1. Select the Add CGI feature when installing IIS

2. Install PHP,

2.1 Download NTS version (non-thread-safe version) Zip compression package, download the corresponding VC + + runtime (download link on the left side of the PHP website download page)

2.2 Install VC + + runtime, unzip the PHP package to any directory (for example: "C:\Program files\php")

3. Copy the php.ini-production from the C:\Program files\php directory and rename it to PHP.ini
Open php.ini with Notepad
Make the following changes:
Extension_dir = "C:\Program files\php\ext" #设置php模块路径
Date.timezone = Asia/shanghai #设置时区为中国时区
Cgi.force_redirect = 0 #开启以CGI方式运行php
Fastcgi.impersonate = 1
Cgi.rfc2616_headers = 1

The following PHP extension module, select on as required, cancel the preceding semicolon to start the corresponding extension module
; Extension=php_curl.dll
; Extension=php_gd2.dll
; Extension=php_mbstring.dll
; Extension=php_exif.dll
; Extension=php_mysql.dll
; Extension=php_mysqli.dll
; Extension=php_sockets.dll
; Extension=php_xmlrpc.dll
; Extension=php_pdo_mysql.dll

4. Open IIS to add the application pool and add the Web site. (This step is the same as adding a normal. NET site)

5. Select the newly added Web site and open the handler mappings to add the module mappings

6. Add the default document, "index.php"

7. Open the physical location folder of the website, add a text file, rename "index.php" and enter:

<? PHP Phpinfo ();? >

8. Open the site in a local browser, such as normal display is the installation, configuration PHP success
9. Delete the index.php file

iis+php (FastCGI)

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.