variable variables?

Karoly Negyesi chx1975 at
Mon Jan 2 15:40:21 UTC 2012


Nginx provides the value of the cookie "foo" in $cookie_foo . Is it
possible to read "foo" from the URL? In PHP you would use two dollar
signs for this kind of indirection.

Drupal sets the name of session cookie based on the cookie domain. I
am running SSI (reading from Redis via Webdis) and I would like to
read some user specific information which is stored in a Redis hash
named after the sesion name with a key of the value of the session
cookie. So the SSI command would be something include
virtual="/user/SESSnameofthesession". So I need to rewrite that into
something like /redis/SESSnameofthesession/${COOKIE_$SESSnameofthesession}.


Karoly Negyesi

Ps. Sorry if i sent two copies of this.

More information about the nginx mailing list