Can't make 301 redirect - need help please

Discussion in 'Site & Server Administration' started by YSeo, Nov 30, 2008.

  1. #1
    Hi everyone,

    I have a website which google shows at the non-www version . I would like to make google change it to the www version.

    I was trying to do 301 redirect on windows server from non-www to www with the following instructions:

    "
    Place the following code above your <html> tag or <!DOCTYPE>, if you have one:

    <%@ Language=VBScript %>
    <%
    response.status="301 moved permanently"
    Response.AddHeader "Location", "http://www.domain.com/file-location.html"
    %>
    "

    once I do like above , firefox tells me that the redirect doesn't seem to be ending.

    is there any way I can resolve this matter as soon as possible ? I already changes my preferred domain with google webmaster tools but the redirect is very important as well for google.

    Thank you very much.
     
    YSeo, Nov 30, 2008 IP
  2. kailash

    kailash Well-Known Member

    Messages:
    1,248
    Likes Received:
    42
    Best Answers:
    0
    Trophy Points:
    190
    #2
    If you do it using code then loop will not be ended and you will get error in your browser. If your host support ISAPI rewrite then you can do it easily. You may refer
    Redirect to www using ISAPI rewrite rule post.

    Kailash
     
    kailash, Nov 30, 2008 IP
  3. YSeo

    YSeo Peon

    Messages:
    533
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    0
    #3
    my hosting is godaddy
    I called them , they have no answer
    isn't weird that such a big company doesn't know how to handle it?
     
    YSeo, Nov 30, 2008 IP
  4. livedomainsearch

    livedomainsearch Peon

    Messages:
    111
    Likes Received:
    3
    Best Answers:
    0
    Trophy Points:
    0
    #4
    livedomainsearch, Nov 30, 2008 IP
  5. livedomainsearch

    livedomainsearch Peon

    Messages:
    111
    Likes Received:
    3
    Best Answers:
    0
    Trophy Points:
    0
    #5
    also try the PHP version:

    <?
    Header( "HTTP/1.1 301 Moved Permanently" );
    Header( "Location: http://www.new-url.com" );
    ?>
     
    livedomainsearch, Nov 30, 2008 IP
  6. YSeo

    YSeo Peon

    Messages:
    533
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    0
    #6
    I am using windows server with go daddy
    does anybody have any clue? it means a lot to me.

    thanks
     
    YSeo, Dec 1, 2008 IP