D
D
DenPolosin2018-03-15 15:39:07
Nginx
DenPolosin, 2018-03-15 15:39:07

How to display another page at the address?

It is required to write a rule in the nginx config that will allow being on the page (it will be written in the address bar):
http://test.ru/katalog/cat/kat/984/otzyvy/
will display the contents of the page:
http://test.ru/katalog/cat/kat/984/?otzyvy=Y
How to implement this?
Tried like this:

rewrite ^/katalog/(.+)/otzyvy/$ ^/katalog/$1/ permanent;

It just redirects.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
B
Boris Korobkov, 2018-03-15
@BorisKorobkov

rewrite ... permanent;

nginx.org/ru/docs/http/ngx_http_rewrite_module.htm...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question