Forum Discussion
Colin_Walker_12
Jan 26, 2007Historic F5 Account
Unless I'm mis-interpreting the request, the HTTP::respond command isn't going to produce the desired results. The HTTP::respond command is going to send a response to the client, whereas I believe what xf6svrb is looking for is to modify the client's originally requested URI, if it's empty, to contain "ghi". Is that correct?
If so, you'd want logic something like this:
when HTTP_REQUEST {
if { [string tolower [HTTP::uri]] starts_with "/abc"} {
pool mywebsite.com-abc
} elseif { [string tolower [HTTP::uri]] starts_with "/def"} {
pool mywebsite.com-def
} else {
if { [string length [HTTP::uri] < 2] } {
HTTP::uri "/ghi/"
}
pool mywebsite.com-ghi
}
}
HTH,
Colin