Forum Discussion
Fluidetom_12222
Feb 22, 2017Cirrus
Eventually this is what I implemented.
Thanks for your help.
when HTTP_REQUEST {
if { [string tolower [HTTP::host]] equals "oldsite.domain.com" }
{
set NEWURI [string map "oldsite newsite" [HTTP::uri]]
set NEWURI [string map "oldstring newstring" $NEWURI]
set NEWURL https://newsite.domain.com$NEWURI
HTTP::respond 200 content "
Your page has moved !
Your page has moved !
The website you have requested has been migrated to
You will be automatically redirected to the new address in 5 seconds.
Please bookmark the next page.
Thank you for your cooperation.
" noserver
return
}
}