Looking to setup an iRule that will allow users calling one of our URL’s to be redirected to the same URL, but with a specific URI appended. I don’t know how to write the iRule syntax, so any help would be appreciated.
Example: User calls https://m.mysite.org, get’s redirected to https://m.mysite.org/User/MobileSiteHome/Start
Try this:
if { [HTTP::uri] equals “/” } {
HTTP::redirect “https://m.mysite.org/User/MobileSiteHome/Start”
}
the following iRUle should be able to do what you want
when HTTP_REQUEST {
HTTP::redirect “https://[HTTP::host]/User/MobileSiteHome/Start”
}
If you only want to send to the URI if the if the host equals m.mysite.org then something like the following
when HTTP_REQUEST {
if { [HTTP::host] equals “m.mysite.org” } {
HTTP::redirect “https://[HTTP::host]/User/MobileSiteHome/Start”
} else {
HTTP::redirect “https://[HTTP::host]”
}
}