Forum Discussion
When to use HTTP::uri vs HTTP::path, contains vs matches
Simply put, if you are calling the HTTP::path, you are simply asking the iRule to apply your "if statement" to the HTTP::uri in the http traffic up to where it sees a query sign .i.e "?" .
In your case, http://www.test.com/dir/page.php?=data
HTTP::path = /dir/page.php
HTTP::uri = /dir/page.php?=data
Whichever you choose, the operand in the "if statement" will apply on the HTTP:: content.
when HTTP_REQUEST { if {[HTTP::uri] contains "php" } { pool php_pool } }
OR
when HTTP_REQUEST { if { [HTTP::path] contains ".php" } { pool php_pool } }
Will give you the same result.
I hope this helps :)
Recent Discussions
Related Content
* 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