How to respond with a 301 permanent redirect?
in aFleX
Posted by TODDH
Guys,
Do we have any way of responding with a 301 (permanent redirect)? I need a way to inform the search engines that my customers location is permanently moved.
Thanks,
-Todd-
Guys,
Do we have any way of responding with a 301 (permanent redirect)? I need a way to inform the search engines that my customers location is permanently moved.
Thanks,
-Todd-
0
Comments
You can use the HTTP::respond command.
syntax:
HTTP::respond <status code> [content <content Value>] [<Header name> <Header Value>]+
So you can specify headers (and set cookies) as well
example:
when HTTP_REQUEST { if { not ([HTTP::host] starts_with "www") } { HTTP::respond 301 Location "http://www.abc.com/" } }