Forum Discussion
RainingBlood_18
Oct 01, 2017Nimbostratus
Irule to amend URI
Hi,
I'm looking to do something like this: https://www.mysite.com/path/search?SomeDynameicText rewrite to something like this https://www.mysite.com/path/search/v1?SomeDynameicText
I have got the following, but it doesn;t seem to work
when HTTP_REQUEST {
if { [HTTP::uri] contains "/search?" } {
HTTP::redirect "https://[HTTP::host]/search/v1?[HTTP::uri]"
}
}
- RainingBlood_18Nimbostratus
sorted by using [HTTP::query]
- Faruk_AYDINNimbostratus
when HTTP_REQUEST { if { [HTTP::uri] contains "/search?" } { HTTP::redirect "https://[HTTP::host]/search/v1?[HTTP::query]" } }
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