Forum Discussion
ryan_haig_15019
Nimbostratus
Apr 08, 2014IRule URL and URI redirection
I would like to create a IRule to do the following:
Users goes to "http://m.test.com/avalanche/SymbolSearch/?pattern=/HELLOWORLD"
I would like to change that on the F5 to
"http://query.test.com/SymbolSearch/?pattern=/HELLOWORLD"
I would like to change the URL to "query.test.com" and remove the "/avalanche" but preserve the rest.
Thanks!!
1 Reply
- Eugene_Reznik_1
Nimbostratus
You probably want something like this
when HTTP_REQUEST { if { [string tolower [HTTP::host]] equals "m.test.com" } { HTTP::respond Location "http://query.test.com[substr [HTTP::uri] 10 0]" } }- This code has not been tested.
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