Multipule Map modules

token nginx-forum at nginx.us
Tue Nov 8 05:20:21 UTC 2011


Hi, António that is exactly wath is was trying to accomplish  id didn't
know i had to use the "~" at the beginning of the map key.
Thank you

>Do you mean that the request URI can contain both /pep and /sub?Like 
> this:

> http://example.com/sub/pep/other-stuff-if-any

> If so then your matching must be done with a regex:

> map $uri $variable1 {
> default 11;
> ~/sub 7;
> }

> map $uri $variable2 {
> default 78;
> ~/pep 23;
> }

Posted at Nginx Forum: http://forum.nginx.org/read.php?2,217936,217959#msg-217959



More information about the nginx mailing list