赞
踩
因为网速现在,下载XAMMP真是太慢了,不如手动安装nginx+php快速,就是配置稍微麻烦一些,小记如下
nginx下载 http://nginx.org/en/download.html
php下载 http://windows.php.net/download/
mysql下载 https://dev.mysql.com/downloads/installer/
mysql5.7的windows安装包完全体竟然有378.8M,网速慢的时候下起来,呵呵
将下载的压缩包解压到C:/wnp
在php-7.1.10目录,将php.ini-development复制一份,副本改为php.ini,打开php.ini
找到:;date.timezone = 先去前面的分号再改为 date.timezone = Asia/Shanghai
; error report
error_reporting = E_ALL
display_errors = On
; CGI 设置
cgi.force_redirect = 1
cgi.fix_pathinfo = 1
fastcgi.impersonate = 1
cgi.rfc2616_headers = 1
其他按需要修改即可
启动php
运行cmd切换到php目录下php-cgi.exe -b 127.0.0.1:9000 -c php.ini
#location / {
root C:/wnp/nginx/html;
index index.php index.html index.htm;
#}
location ~ \.php$ {
# root html;
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcig_read_timeout 120;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
}
在nginx-1.13.5目录双击nginx.exe即可启动nginx
运行cmd切换到nginx目录下nginx.exe -s reload重载
停止php-cgi和nginx.exe,保存为stop.bat
@echo off
echo Stopping nginx...
taskkill /F /IM nginx.exe > nul
echo Stopping PHP FastCGI...
taskkill /F /IM php-cgi.exe > nul
exit
赞
踩
赞
踩
赞
踩
赞
踩
赞
踩
赞
踩
赞
踩
赞
踩
赞
踩
赞
踩
赞
踩
赞
踩
赞
踩
赞
踩
赞
踩
赞
踩
赞
踩
赞
踩
赞
踩
赞
踩
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。