support for rewriteRule in cookie flag
Posted
by kookadjou
on Stack Overflow
See other posts from Stack Overflow
or by kookadjou
Published on 2010-06-10T22:51:16Z
Indexed on
2010/06/10
22:52 UTC
Read the original article
Hit count: 354
I'd like to use $1 in the [cookie] flag of rewriteRule. I want to create a cookie with a part of the request url as in the following:
RewriteRule ([0-9])/. - [CO=cookieName:$1:example.com]
for example: If the request url is: http://www.example.com/1234, i want to set a cookie name "cookieName" with the value "1234"
it seems no cookie is add when a dollar sign ($1) is between the cookie directive.
Is this something possible ?
Thank you
© Stack Overflow or respective owner