RonR10_181817
Jun 10, 2015Nimbostratus
iRule Redirection using Switch
Hello all - I am requesting your expertise to determine why this iRule doesn't work 100%. I am trying to redirect users to a page upon entering the site.
1) http://www.site1.com or http://site1.com works correctly and redirects me to the maintenance page. 2) But if I go to http://www.site1.com/MyAccount or http://site1.com/MyAccount, it does NOT redirect me to the maintenance page.
Thanks in advance! Ron
when HTTP_REQUEST {
if { (([HTTP::host] equals "site1.com") or ([HTTP::host] equals "[www.site1.com](http://www.site1.com)")) }{
switch -glob [string tolower [HTTP::uri]] {
"/" -
"*MyAccount*"
{
HTTP::uri "/MaintenancePage.html"
}
}
}
}