Forum Discussion
David_Noonan_67
Nimbostratus
Oct 08, 2007Syntax for "matches" and "matches_regex"
We've got an iRule that contains the following code. It works fine but I find the repetition offensive.
elseif {[HTTP::uri] contains "fx1"} {
use pool Xyzzy
}
elseif {[HTTP::uri]...
Deb_Allen_18
Oct 09, 2007Historic F5 Account
Just realized you'd have to also include some wildcards if you want to simulate the "contains" command:
elseif {[HTTP::uri] matches_regex {.*fx[1234].*}} {
use pool Xyzzy
}
which should read:
open brace, period, asterisk, fx, open square, 1234, close square, period, asterisk, close brace
/deb
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