Forum Discussion
Bob_10976
Nimbostratus
Oct 22, 2008Redirecting Only Specfic URL Address
Hello All,
I've been task to setup a iRule that will redirect a url, subsite.mysite.com to mysite.com It actually seems pretty simple but the problem is subsite.mysite.com typically h...
Bob_10976
Nimbostratus
Oct 29, 2008Hey sorry haven't gotten back sooner...
sklingner...I did try your suggest but it didn't work and by reviewer it i relized I had host and not URI, I changed host to URI and it still didn't work.
When changing it it URI it doesn't do anything, it was as if I didn't put in an iRule at all. But if I changed the uri back to host it would go back to the orginal problem, it rediected everything.
I tried something a bit different, its below, but again it didn't work either, nothing got redirected
when HTTP_REQUEST {
if { ([string tolower [HTTP::uri]] == "subsite.mysite.com") || ([string tolower [HTTP::uri]] == "www.subsite.mysite.com")} {
HTTP::respond 301 Location http://mysite.com/
}
}
I did replace the "==" with "equals" but no difference and I did add the trailing "/" and no change...
Any suggestions?
Thanks
Bob
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
