Forum Discussion
Matt_Breedlove_
Jul 17, 2012Nimbostratus
switch glob tcl string match support
Hi All
When using switch -glob, I know it supports square bracket char ranges such as [a-f], but does it support either of these?
Either "a" or "d" or "f"
[a,d,f]
o...
Michael_Yates
Jul 18, 2012Nimbostratus
Hi Matt,
I am guessing that you are trying to do something like this.
when HTTP_REQUEST {
switch -glob [string tolower [HTTP::uri]] {
"/test[a,c,e]" { HTTP::redirect "http://www.google.com" }
"/test[b,d,f]" { HTTP::redirect "http://www.yahoo.com" }
}
}
The Virtual Server IP Address or the application FQDN that will get you to the Virtual Server + /test and the letter will give you the varying results.
Hope this helps.
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