1.首先,安装IIS7及IIS应用程序组件(CGI、ASP、ISAPI等一并安装) 2.下载PHP5.5以后版本,http://windows.php.net/download/ 3.将下载完的PHP程序解压,并拷贝到安装目录,例如:E:\PHP(这里以此路径为例,可根据实际修改) 4.进入PHP的安装目录,将“php.i
1.首先,安装IIS7及IIS应用程序组件(CGI、ASP、ISAPI等一并安装)
2.下载PHP5.5以后版本,http://windows.php.net/download/
3.将下载完的PHP程序解压,并拷贝到安装目录,例如:E:\PHP(这里以此路径为例,可根据实际修改)
4.进入PHP的安装目录,将“php.ini-production”重命名为“php.ini”
5.编辑“ php.ini ”里面以下代码:
找到 extension_dir 修改为 extension_dir = "E:\PHP\ext"
找到 date.timezone 修改为 date.timezone = Asia/Shanghai
找到 fastcgi.impersonate 修改为 fastcgi.impersonate = 1
找到 cgi.fix_pathinfo 修改为 cgi.fix_pathinfo=1
找到 cgi.force_redirect 修改为cgi.force_redirect = 0
并将以上代码前面分号去掉
根据自己的需要选择php extensions,这里介绍以下几个重要的,查找以下代码并去掉每行前面的分号;即启用组件
;extension=php_dbase.dll //可选
;extension=php_gd2.dll //支持GD库,必选
;extension=php_mbstring.dll //不选PhpMyadmin会出红色提示,必选
;extension=php_mcrypt.dll //不选以及不把libmcrypt.dll复制到C:\WINDOWS\system32文件夹,PhpMyadmin会出错误提示:无法载入mcrypt扩展,必选
;extension=php_mssql.dll //支持MSSQL的,可选
;extension=php_mysql.dll //支持MYSQL的,必选
在IIS 和
分别添加php路径
重启IIS 后 PHP文件能正常访问
如果出现500错误
检测方法
看弹出错误
如果是没有找到msvcr110.dll php 导致出现FastCGI进程退出或缺少
下载 安装Visual C++ Redistributable for Visual Studio 2012
地址http://www.microsoft.com/zh-CN/download/details.aspx?id=30679
安装后 PHP正常访问

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

Video Face Swap
Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

EditPlus Chinese cracked version
Small size, syntax highlighting, does not support code prompt function

SublimeText3 English version
Recommended: Win version, supports code prompts!

PhpStorm Mac version
The latest (2018.2.1) professional PHP integrated development tool

Dreamweaver Mac version
Visual web development tools

Safe Exam Browser
Safe Exam Browser is a secure browser environment for taking online exams securely. This software turns any computer into a secure workstation. It controls access to any utility and prevents students from using unauthorized resources.
