Forum Discussion
Cory_50405
May 12, 2014Noctilucent
Have you tried inserting a logging statement before the redirects within this switch statement to verify that the query is matching one of the strings? Or that the host is even matching oldforum.olddomain.com to get to evaluation of the nested switch?
when HTTP_REQUEST {
switch [string tolower [HTTP::query]] {
"tid=" {
log local0. "Query tid= matched"
HTTP::redirect "https://newforum.newdomain.com/default.aspx?g=posts&t=[URI::query [HTTP::uri] tid]"
return
}
"fid=" {
log local0. "Query fid= matched"
HTTP::redirect "https://newforum.newdomain.com/default.aspx?g=topics&f=[URI::query [HTTP::uri] fid]"
return
}
"c=" {
log local0. "Query c= matched"
HTTP::redirect "https://newforum.newdomain.com/default.aspx?g=forum&c=[URI::query [HTTP::uri] c]"
return
}
}
}