Forum Moderators: phranque

Message Too Old, No Replies

Unique mysite.com to www.mysite.com major redirect problem

hosting company less than helpful

         

steveb

11:16 pm on May 28, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Right now Google is cacheing three different versions of my homepage
[mysite.com...]
[mysite.com...]
[mysite.com...]

I want to redirect mysite.com to www.mysite.com (and the other one also).

I'm on a non-IP account with a major hosting company, and use FrontPage which is "supported" by the hosting company.

When I try to use a 301 redirect:
redirect 301 /mysite.com/ [mysites.com...]
it does not work, does nothing. When I do:
redirect 301 / [mysites.com...]
I get a 500 error.

My hosting company sent me this mod rewrite:
RewriteEngine On
RewriteCond %{HTTP_HOST} ^mysite.com
RewriteRule /(.*) [mysite.com...]

This succeeds in only making the banners on my mysite.com page disappear/not found. The mysite.com page continues to appear without the www.

I'm at my wits end here as I suspect these "duplicate" pages are hurting me quite a bit with Google.

The tech "support" suggested I try something with an index.cgi file, which sounds absurd since I've never seen that mentioned for this piddly little redirection issue.

The other code in my .hataccess file (not including the authentications stuff is:

# -FrontPage-

IndexIgnore .htaccess */.?* *~ *# */HEADER* */README* */_vti*

<Limit GET POST>
order deny,allow
deny from all
allow from all
</Limit>
<Limit POST PUT DELETE>
order deny,allow
deny from all
</Limit>

Any good ideas (besides dumping frontpage) would be appreciated. Again, the point is, all I want to do is redirect mysite.com to www.mysite.com

jdMorgan

11:24 pm on May 28, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



steveb,

Try this, exactly as shown, changing only "mysite" in both lines :


RewriteEngine on
RewriteCond %{HTTP_HOST} !^www\.mysite\.com
RewriteRule ^(.*)$ http://www.mysite.com/$1 [R=301,L]

HTH,
Jim

steveb

11:38 pm on May 28, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Aiiiyah, that worked... but then I couldn't use Front Page to publish the site. I get:

403 Forbidden
Forbidden You don't have permission to access /_vti_bin/shtml.exe/_vti_rpc on this server.

Removing the code allows me to publish via Frontpage again.

jdMorgan

12:23 am on May 29, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



steveb,

I believe you have to use FTP to download the existing .htaccess file to your computer, then make the changes, and then FTP it back to the server. If that doesn't help, we'll have to wait until someone comes along who uses FrontPage/FP extensions - I won't put up with its sheningans myself...

Jim

steveb

2:30 am on May 30, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Asked instead in WYSIWYG forum:

[webmasterworld.com...]