Difference between revisions of "Change URL/Host"
From Tech-Wiki
(Created page with "Category:F5 Networks '''Back to iRules''' when HTTP_REQUEST { set host [HTTP::host] set path [HTTP::path] if { not ([HTTP::host] starts_w...") |
|||
(One intermediate revision by the same user not shown) | |||
Line 3: | Line 3: | ||
when HTTP_REQUEST { | when HTTP_REQUEST { | ||
− | + | set host [HTTP::host] | |
− | + | if { not ([HTTP::host] starts_with "www") } { | |
− | + | HTTP::redirect https://www.${host} | |
− | + | ||
} | } | ||
} | } |
Latest revision as of 14:19, 17 May 2021
when HTTP_REQUEST { set host [HTTP::host] if { not ([HTTP::host] starts_with "www") } { HTTP::redirect https://www.${host} } }