Forum Discussion
Sergio_Magra
Nimbostratus
Oct 08, 2013URI based redirect
Hi all,
We need to make a redirection based on certain URI, but it does not work due to be incompleted. We made an iRule for this.
We need that if we receive the following URI:
http:...
David_123674
Nimbostratus
Oct 08, 2013The best way to do what you are wanting is as follows:
when HTTP_REQUEST {
set host [HTTP::host]
set uri [HTTP::uri]
switch -glob [HTTP::path] {
"somepage.html" {
HTTP::respond 302 Location "https://$host$uri"
)
default {
}
}
}
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