Nov 06, 2010
404 status issue
Hello All, I'm curious as this is weird behavior I've encountered with this set of code: when HTTP_RESPONSE { if { ([HTTP::status] equals "404") } { if a 404 is ret...
Something like this would work:
when HTTP_REQUEST {
set hostvar [HTTP::host] } }
when HTTP_RESPONSE {
if { [HTTP::status] eq "404" } {
if a 404 is returned, send a 301 redirect for our custom 404 page
HTTP::respond 301 Location "http://$hostvar/portal/site/erp/404/" } }
Let me know if you have any issues with that.