Forum Discussion
Albert__Tase_70
Nimbostratus
Jan 03, 2007ok here it is again now all but the last part is excepted
when HTTP_REQUEST {
set host [string tolower [HTTP::host]]
set ua [string tolower [HTTP::header "User-Agent"]]
set uri [HTTP::uri]
if { ($host contains "demo.nature.com") || ...
Deb_Allen_18
Jan 03, 2007Historic F5 Account
Hi Al --
Remove one of the closing curly braces and move the one preceding the HTTP::redirect command to the line above:
} elseif { [HTTP::host] equals "www.nature.com" && [HTTP::uri] starts_with "/rss/" && [HTTP::uri] ends_with "/index.html" }{
HTTP::redirect "http://www.nature.com/webfeeds/index.html"
first closing curly brace terminates "if" statement
}
second one terminates HTTP_REQUEST event
}
third one terminates iRule
}
The next time you post, PLEASE post follow-up questions on the same topic on the same thread for continuity rather than beginning a new topic each time. Also, please try to follow Hoolio's suggestions re: formatting your code for readability (will make errors like that above more obvious).
HTH
/deb
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