Forum Discussion
samigo_81875
Nimbostratus
Sep 03, 2013Search replace uri
Hi,
I want to search replace using regex
/content/learning//production
TO
/content/learning/production
Tried below but the regex doesn't work
if { [URI::decode [string tolower [HTTP::ur...
samigo_81875
Nimbostratus
Sep 03, 2013I think I got it working with below
if { [URI::decode [string tolower [HTTP::uri]]] matches_regex "/content/learning/(.)/production/frshdb" } { regsub {learning/(.)/production} [HTTP::uri] "learning/production" replaceURI HTTP::respond 307 noserver Location "https://myserver.com$replaceURI" }
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