Is it possible to rewrite URL with HTTP 301 and make that last rule in
current ruleset? For example, in apache one can use flags “[R=301,L]” ,
but
how can one do it in nginx? I tried using following, but it returned
syntax
error:
Config: rewrite /members /users permanent last;
Error: nginx: [emerg] invalid number of arguments in “return” directive
in
/etc/nginx/nginx.conf:60
On Wed, Nov 19, 2014 at 2:44 PM, Francis D. [email protected]
wrote:
If not, can you show the config snippet, the request you make, and the
response you get instead of the response you expect?
Thanks for the reply Francis. May be permanent 301 redirect also implies
last, but I couldn’t find that in documentation. I don’t have any config
to
share as I am just exploring options and that’s the only rule I have (so
it
doesn’t matter right now but I may need it in future).