What a mess! Just
what are you trying to accomplish here?
The first 3 rewrite lines are pretty straightforward:
RewriteEngine On
RewriteCond %{http_host} ^site.com
RewriteRule ^(.*) http://www.site.com/$1 [R=301,L]
It changes
http://site.com/... to
http://www.site.com/... so search engines only index one version.
I have seen problems, at least on LP servers, with firing off more than one 301 redirect at a time. Something just doesn't seem to work right, even though in theory it should be OK. So, if more than one of your 301 redirects fire off, that may cause trouble.
Now, just what are you trying to accomplish with the rest of this code? By default, the
DirectoryIndex entry is
index.html index.htm index.php home.html on LP servers. Given a directory name but no filename, the server will look for "index" files in that order.
RewriteRule ^/?$ "http\:\/\/www\.site\.com\/index\.php" [R=301,L]
is unnecessarily complicated. First, the
Replacement String on the right is
not a Regular Expression, and should not have all those escapes in it:
RewriteRule ^/?$ http://www.site.com/index.php [R=301,L]
What it's saying is "If the URI is empty or just a slash, send the request to index.php". That could be better done as a rewrite:
RewriteRule ^/?$ /index.php
But if you leave the DirectoryIndex alone, it will go to index.php anyway. (Note that it will go to the
root's index.php, not the index.php in a directory.)
RewriteCond %{HTTP_HOST} ^.*$
RewriteRule ^info/index.html$ "http\:\/\/www\.site\.com\/index\.php" [R=301,L]
again can be simplified:
RewriteCond %{HTTP_HOST} ^.*$
RewriteRule ^info/index.html$ http://www.site.com/index.php [R=301,L]
and says "In all cases (any domain name) redirect info/index.html to /index.php". It should match only info/index.html, and the RewriteCond can probably be omitted. Do you really want this to be a 301 redirect? That tells search engines to remove any listing they have for info/index.html and replace it with index.php. If you're just doing some SEO, and want info/index.html to continue to be the public address, use
RewriteRule ^info/index.html$ /index.php
Again, note that it's going to your root index.php.
The same thing holds for the "referral/" entry.
Your last statement
redefines DirectoryIndex to look
just for sitehome.php -- it doesn't
add that name to the list. What did you intend here? Do you want index.html, index.htm, and index.php to be ignored, and look only for sitehome.php if no filename is given?