Forum Discussion
Nov 08, 2017
Try this rule instead (untested for syntax errors)?
when HTTP_REQUEST {
if { [HTTP::host] eq "mobile.domain.com" } {
HTTP::respond 301 Location "https://mobile.newdomain.com[HTTP::uri]"
} elseif { [string tolower [HTTP::uri]] contains "/mobile" } {
HTTP::respond 301 Location "https://mobile.newdomain.com[string map -nocase { "/mobile" "" } [HTTP::uri] ]";
}
}