Forum Moderators: open
Luckily, the very first line of code on all my pages is an include to a header.php file..
Is there any issues for google in adding this line of code? This way if google or anyone comes to sitename.com/dir/file.php, they are automatically sent to www.sitename.com/dir/file.php
<?
if (strlen($HTTP_HOST=="sitename.com"))
{
header("HTTP/1.1 301 Moved Permanently");
header("Location: [$HTTP_HOST$REQUEST_URI");...]
//exit();
}
?>
I decided to leave the exit commented out, just in case there was some type of error, then my visitors will still see the page except with a small parse error at the top..
Thoughts?