November 05, 2010 01:49PM
> Classic "redirect everything" example contains
> '?'. See e.g. here:
> : server {
> : listen 80;
> : server_name;
> : rewrite ^$request_uri?;
> : }

Well, it sure does. does not show the '?' and I (think) I've read many other configurations that don't have it, but perhaps I'm just getting old.

> rewrite is expected to preserve original args in
> all cases (either
> preserve as is, or append if you added other
> arguments) unless you
> specified trailing '?'.

Got it. However, if you use $request_uri, doesn't that always preserve the original args by itself? I'm having trouble thinking of an example where you would NOT want a question mark after $request_uri in a rewrite statement.


Subject Author Posted

rewrite with $request_uri auto appends args

NCRonB November 05, 2010 01:08PM

Re: rewrite with $request_uri auto appends args

Maxim Dounin November 05, 2010 01:30PM

Re: rewrite with $request_uri auto appends args

NCRonB November 05, 2010 01:49PM

Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 110
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 466 on July 09, 2024
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready