E
E
Eugene2015-12-26 20:22:33
PHP
Eugene, 2015-12-26 20:22:33

Curve %26request_uri. How to win?

Hello. In general, such a "problem".
New website, decided to work via https. Certificates are received, work.
And the redirect goes from domain.name/*.php to https://domain.name/*.php
But if the request_uri does not appear, i.e. the transition comes from domain.name , then the browser swears, and in the address bar this:
https://domain.name%26request_uri.
NGinX cfg:

server {
       listen         80;
       server_name    domain.name www. domain.name;
       return         301 https://$server_name$request_uri;
}

The error is not in mod_rewrite, if I remove it, it still remains. I guess that's where the error is. But how to win?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
N
nirvimel, 2015-12-26
@xmax

return 301 https://$host$request_uri;

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question