Forum Discussion
F5Hopper_28651
Nimbostratus
Aug 15, 2016Geolocation irule for states
so I have read many irules on the dev site, creating mine.
when HTTP_REQUEST {
if { ([string tolower [HTTP::uri]] starts_with "/testingpage") } {
Parse the client IP from the CDN header
...
janholtz
Altostratus
Aug 15, 2016Simple mistake, (I've done it myself) : set state [string tolower [whereis $client_ip abbrev]]
switch $state {
"NJ" -
"ID" {
string tolower will never have a "NJ" or "ID" result,
try "nj" or "id"
🙂
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)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
