Forum Discussion
Joe_Pipitone
Nimbostratus
Dec 23, 2009Rewrite at the root of the domain
I have a rewrite rule that I'm already using to redirect the beginning of a domain request while keeping the URI as the user typed it in.
I want to redirect all requests to our-website.com/in...
The_Bhattman
Nimbostratus
Dec 24, 2009Hi Joeseph,
You could do the following
when HTTP_REQUEST {
if { ([HTTP::host] eq "our-website.com") } {
switch -glob [string tolower [HTTP::uri]] {
"/" { HTTP::redirect "http://another-website.com/portals/water.aspx" }
default { HTTP::redirect "http://another-website.com/[HTTP::uri]"
}
}
}
I hope this helps
Bhattman
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