Forum Discussion
Dan_Kop_23221
Nimbostratus
Dec 03, 2015Redirect :: URI with # symbol
Have a URI that has "//hello"
We are looking to redirect anything that comes in with this to another URL. Here is what we have so far:
when HTTP_REQUEST {
if { [str...
Stanislas_Piro2
Cumulonimbus
Dec 03, 2015Hi,
your irule is not working for 2 reasons:
- is not sent to the server
-
HTTP::host does not contain URI... in the request "" :
- [HTTP::host] is www.sitea.com
- [HTTP::uri] is /
The good syntax may have been (concatenate both variables):
when HTTP_REQUEST {
if { [string tolower [HTTP::host][HTTP::uri]] equals "www.sitea.com//hello" } {
HTTP::redirect "https://siteb.com/"
}
}
But this is not possible... is a Fragment identifier managed locally by the browser, never sent to the server...
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