variable for absolute requested url

Ben Blakley lists at ruby-forum.com
Wed Oct 1 23:26:01 MSD 2008


Hello,

I'm not sure if I'm missing something obvious here, but is there a
variable available that can be used in if conditions that has the entire
requested URL? This is, so you could have something like the following:

if ($url = "http://www.example.com/blog") {

}


If not, is the best workaround to use the "set" directive to create a
new variable and then use that new variable in the if statement?
Something like:

set $url "$host$uri";

Thanks for the help.

Ben
-- 
Posted via http://www.ruby-forum.com/.





More information about the nginx mailing list