Forum Discussion
Tony_Lee_73702
Nimbostratus
Oct 13, 2005HTTP rewrite for lots of URLs
Hi all,
I've got a pair of 3400s running 9.0.5. I've created a HTTP-based VS load balancing traffic against a handful of IIS servers.
I'm in a web hosting environment and I've g...
Nov 01, 2005
As for the case comparison, why don't you just store all your values in lower case in the redir_class and then convert the host and uri to lowercase before calling findclass?
when HTTP_REQUEST {
log start
set lookup [string tolower [HTTP::host][HTTP::uri]]
log $lookup
set mapping [findclass $lookup $::redir_class " "]
if { "" ne $mapping } {
redirect to "$mapping"
log "[HTTP::host] to $mapping"
} else {
set mapping [findclass [string tolower [HTTP::host]] $::redir_class " "]
if { "" ne $mapping } {
redirect to "$mapping"
log "[HTTP::host] to $mapping"
} else {
log "no hit [HTTP::host]"
redirect to "http://www.deere.com"
}
}
}As for the "+" character, I just tested it out and didn't find an issue with that character. Have you tried this and had problems, or were you just wondering whether it would work or not.
-Joe
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