Forum Discussion
Andrea_Arquint
Oct 20, 2010Nimbostratus
cookie insertion
Hi
How can I set a cookie in the clients browser if he makes a request to a specific /folder/ ???
thanx
bb
Chris_Miller
Oct 20, 2010Altostratus
Posted By bigbrother on 10/20/2010 06:47 AM
@ Chris
I did create the iRule like you recommended:
when HTTP_REQUEST {
if { [string tolower [HTTP::uri]] starts_with "/test" } {
HTTP::cookie insert name "NewCookie" value "test"
}
}
But after I request /test there is no cookie show in Firefox???
Is there something more to set?
To which domain does this cookie belong to?
Kind regards
Andrea
What's the exact URI you're testing?
Would it be like "www.sample.com/test" ?
Try "HTTP::cookie insert name "NewCookie" value "test" path /"
The cookie belongs to whatever domain you're accessing. In my example, it would be for "www.sample.com"
Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects