Answer the question
In order to leave comments, you need to log in
How to deal with 404 errors on urls without an extension at the end?
Recently completely switched from apache to nginx. Everything would be fine, but there was a problem with self-written scripts in php.
The domain is linked, the site itself consists of one index.php, a couple of pictures and css. Made another 404.php page for the corresponding error. I registered the following in the nginx config: I
error_page 404 /404.php;
open site.ru/blablabla.php - everything is processed as it should, in the browser exactly what is written in the 404.php file.
But it’s worth opening site.ru/blablabla - what opens in my index.php.
Googled all day looking for a solution - nothing. I read the official manual - also nothing. How to solve this problem? I'm sure this is a simple question and I don't see some banal thing, but I'm already tired of looking for a solution to the problem.
Answer the question
In order to leave comments, you need to log in
But it’s worth opening site.ru/blablabla - what opens in my index.php.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question