U
U
unlik2019-03-14 01:18:38
Nginx
unlik, 2019-03-14 01:18:38

nginx settings?

There is such htaccess
RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME}\.php -f
RewriteRule ^(.*)$ $1.php
The site was moved to a server where nginx is used, now internal pages give a 404 error. How to correctly write such a redirect for the nginx config?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
S
Softer, 2019-03-14
@Softer

Most likely something like this:
try_files $uri $uri/ $uri.php;

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question