Forum Discussion
Joel_Moses
May 02, 2012Nimbostratus
9.4.6 had some oddities about placement of curly-braces in iRules. Try this:
when HTTP_REQUEST {
switch -glob [string tolower [HTTP::host]] {
"www.site1.com" -
"site1.com" {
HTTP::redirect "http://www.site-1.com[HTTP::uri]"
}
}
}
I've seen instances where the 9.x parser seemed to think consecutive curly-braces on the same line marked the end of the iRule in the config erroneously. It's been fixed in 10.x and above.