Difference between revisions of "Change URL/Host"
From Tech-Wiki
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} } }