
一、文件准备

稍微整理了下文件,都丢在文末了,你要去官方地址下也成:DirectX Repair(直接用运行库安装包也成)、PHP、MySQL、IIS Rewite和ARR模块、解压软件。

二、DirectX与运行库
管他缺啥,一把梭过去就完事了

三、安装IIS
打开服务器管理器,添加功能

三个下一步,到了 Server Roles 勾上 Web Server(IIS),下一步 Features 勾上 IIS Hostable Web Core

下一步,IIS的功能选择,看着选呗,但是记得把 CGI 勾上

安装完成,开始菜单可以找到IIS管理器

然后把 Rewrite(伪静态等功能) 和 ARR(反代等功能) 模块安上

看来一切顺利,需要的东西都出现了

四、PHP
把PHP放到...还是放到C:\Program Files\吧,经典操作

把目录下的 复制个重命名为 ,打开编辑波(不建议用记事本)
当然,文末提供的包如果不改路径,是开箱即用的,一般不需要改什么
查找下面=前面的部分,如果前面有分号就去掉,并修改后面的部分:zlib.output_compression = On //启用Gzip压缩
max_execution_time = 30 //最大执行时间,按需改
memory_limit = 128M //内存大小限制
display_errors = Off //关闭报错
error_log = C:\Windows\temp\PHP72_errors.log
post_max_size = 100M //最大POST大小,按需改
extension_dir = "C:\Program Files\PHP\7.2.5\ext" //ext文件夹位置
cgi.force_redirect = 0
cgi.fix_pathinfo=1
fastcgi.impersonate = 1
fastcgi.logging = 0
upload_tmp_dir = C:\Windows\temp
upload_max_filesize = 100M //最大上传大小,按需改
date.timezone = Asia/shanghai //时区
session.save_path = "C:\Windows\temp"
session.auto_start = 1
扩展extension=xxxxx //去掉前面的分号以启用对应扩展
我开了这些:curl、fileinfo、gd2、gettext、mbstring、exif、
打开IIS,Hander Mappings ,Add Module Mapping...(模块映射),按下图进行设置


Default Document 添加 index.

phpinfo(); ,好像可以了

五、安装MySQL
Server Only

Stand

其它设置可默认,然后设置密码

完事

WordPress

权限问题
上面我们设置的临时文件夹路径为 C:\Windows\temp ,为正常使用我们要给它访问权限
安全选项卡走一波


文件下载 Windows Server 2019 下IIS10+PHP7.2+MySQL8环境的搭建