: This article mainly introduces nginx configuration in windows. if you are interested in the PHP Tutorial, refer to it. 1. download:
Http://nginx.org/download/nginx-1.8.0.zip
2. decompress the package:
D:/nginx-1.8.0
3. run the following command:
cd nginxstart nginx
Access 127.0.0.1.
Common commands:
Nginx-s stop // stop nginxnginx-s reload // reload the configuration file. you can only run nginx-s quit at runtime // exit nginx
4. modify the root directory:
location / { root D:/html; index index.html index.htm inde.php; }
5. set PHP support
location ~ \.php$ { root D:/html; fastcgi_pass 127.0.0.1:9000; fastcgi_index index.php; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; include fastcgi_params; }
The above introduces the nginx configuration in windows, including some content, and hope to be helpful to friends who are interested in the PHP Tutorial.