Answers for "php file download instead of executing nginx"

PHP
0

php file download instead of executing nginx

server {

   server_name my-domain.com;
   root /usr/share/nginx/html;
   location = favicon.ico { access_log off; log_not_found off; }
   index  index.php;
   location / {
       try_files $uri $uri/ =404;
   }
   location ~ \.php$ {
       fastcgi_pass unix:/run/php-fpm/www.sock;
       fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
       include fastcgi_params;
   }
Posted by: Guest on May-29-2021

Code answers related to "php file download instead of executing nginx"

Browse Popular Code Answers by Language