Forum Discussion
greg_chew_11034
Nimbostratus
Sep 01, 2005http::redirect and http::close and not closing the session.
Hey all.
I am trying to do a redirect to www.foo.com/test.
HTTP/1.0 302 Found
Location: http://www.foo.com/browse/home.html
Server: BIG-IP
Connection: Keep-Alive
...
unRuleY_95363
Sep 01, 2005Historic F5 Account
Ok, I think I know what the problem is... The logical expression operators have very high precendence, and as a result have confused many, many people. In your host check:
if { $host != "www.foo.com" and $host != "foo.com" }It's very likely that the "and" is getting done differently than you expect. I will add some parenthesis to show you the way it is likely being interpreted:if { ($host != ("www.foo.com" and $host)) != "foo.com" }As you can see, this would definitely produce a weird and unexpected outcome.So, try adding some parenthesis like so:
if { ($host != "www.foo.com") and ($host != "foo.com") }and see if that doesn't help straighten out the problem.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
