Forum Discussion
The_Bhattman
Mar 26, 2008Nimbostratus
If I understand you correct you want redirect if all http requests hit a know page_ID. If the page is part of your list you want redirect to an errorpage.
Here is a snippet that may help
foreach item $::redirect_ids {
if { $item == $page_id } {HTTP::redirect "http://$::base_hostname/site/en/us/$item" }
else {HTTP::redirect "http://$::base_hostname/site/us/en/home/Global/We-Have-Redesigned-the-Site.html?cid=ErrorPage$page_id" }
}
You don't need "then", because it's now implicit within irules, using IF statements. I also used redirect because that is essentially what you are doing with the "HTTP::Respond 301"
Hope this helps
/CB