Hi guys,
I’m playing around with irules and im trying to do some smarts around a base url redirect and then a rewrite on sub folders.
So if you hit testdata.com it will redirect you to xyz.com
but if you hit testdata.com/data/* it will rewrite to abc.com/data/*
i cant seem to get it working. any pointers will be awesome.
when HTTP_REQUEST {
if { [string tolower [HTTP::uri]] starts_with "/" } {
HTTP::redirect "https://xyz.com/"
}
if { [string tolower [HTTP::uri]] starts_with "/data/*" } {
HTTP::redirect "http://abc.com/data/*"
}
}