Forum Discussion
obartek_169898
Nimbostratus
May 28, 2015iRule with regex, change string inside URI for another one
Hello,
I want to redirect ( http 301) this request
domain.com/pl/_company-id/SOME_DIGITS
New request should look like this:
domain.com/_company-id/SOME_DIGITS/?language_code
REGEX
...
- May 28, 2015
when HTTP_REQUEST { if {[string tolower [HTTP::uri]] matches_regex {/pl/_company-id/\d+} } { HTTP::redirect "/_company-id/[string range [HTTP::uri] [string last / [HTTP::uri]] end]/?language_code" } }
Dario_19875
Nimbostratus
May 20, 2010Hi,
I've checked the traces, and see that the HTTP GET is first done. In response to that, the 302 redirect is send.
Any idea by which is can replace CLIENT_ACCEPTED?
Thanks,
Dario