F
F
fulltext2018-12-10 09:11:10
Nginx
fulltext, 2018-12-10 09:11:10

Nginx 1.10 doesn't skip link - returns main page?

nginx + apache php_mod Category
link on the site: site.ru/shtroborezy (this is a category in htaccess rules are written)
returns the main page (there must be a category). no redirects in nginx headers
IF RENAME CNC category, for example, site.ru/f_shtroborez - then the category opens.
I didn't notice this with other categories :(
How so? Reserved word :)?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
F
fulltext, 2018-12-11
@fulltext

I found a mistake (for sure, the morning is wiser than the evening ...)!
In nginx host config:

location ~ /.ht {
    deny all;
  }

here we are supposed to forbid viewing files starting with a dot + ht, for example, such as .htaccess
but the rules of regular expressions do not escape the dot - this is any character
, so it turns out that my link contains sht roborezy - access is denied!
Correct code:
location ~ /\.ht {
    deny all;
  }

Thanks to all.

T
TyzhSysAdmin, 2018-12-10
@POS_troi

This is not for Apache with nginx, but for the php engine, which he returned to you and gave the server.
PS Take the time to study the Rewrite rules of Nginx and throw Apache out of the bunch, it's superfluous, it's superfluous everywhere.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question