php 7.4 + nginx quick start on Windows 10 / Server 2012 / 2016 / 2019

5
(1)

This article shows you how to quick install and integrate Nginx and PHP on Windows-based systems.

1. Install Nginx + PHP

Basically, just download zip file and extracts it, no installation.

To install Nginx

  1. Visit http://nginx.org/en/download.html
  2. Download to c:web

nginx/Windows-1.19.8
  1. Extract to C:web

To Install PHP

  1. Visit http://windows.php.net/download/
  2. Download PHP For Windows: Binaries and sources Releases (7.4 -nts-vc15-x64)
  3. Extract to C:webphp

Edit file c:webconfnginx.conf

location / {
            root   html;
            index  index.html index.htm index.php;
        }


        location ~ .php$ {
            fastcgi_pass   127.0.0.1:9999;
            fastcgi_index  index.php;
            fastcgi_param  SCRIPT_FILENAME  $document_root$fastcgi_script_name;
            include        fastcgi_params;
        }

Then run:

php-cgi.exe -b 127.0.0.1:9999

and run nginx…

start c:webnginx.exe

That’s all…

Similar Posts:

2,033

How useful was this post?

Click on a star to rate it!

Average rating 5 / 5. Vote count: 1

No votes so far! Be the first to rate this post.

Scroll to Top