Forum Discussion
im having problems with issuing a 302 with an iRule
Try setting the new HTTP::host as a variable. then call it in the redirect. when HTTP_REQUEST { if { [class match [[string tolower [HTTP::uri]] starts_with DatagroupNAME ]] } { HTTP::respond 302 location "http://$[HTTP::uri]" } }
You could also use a Switch [HTTP::uri] to achieve this.
- eben_259100Jun 23, 2017
Cirrostratus
when HTTP_REQUEST{ switch [HTTP::uri] { "/lorl/"- "/jc.app.settings.svc.webhost/"- "/jc.leader.joe.webhost/"- "/jc.app/settings.svc.webhost/" { HTTP::redirect "http://new.domain.com/[HTTP::uri]"}
}
}
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
* 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