301 redirection

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • jollyhumper
    Confirmed User
    • Mar 2011
    • 400

    #1

    301 redirection

    Hi folks

    I discovered that one of my blogs redirects domain.com --> www.domain.com.

    I discovered this when a automated search for some links yielded into a
    HTTP Error 301 - Moved permanently

    None of my other sites have this automated redirection, and I have no clue why this site does.

    I've searched a lot now, but the fuck can I find out how to change that.

    So, does anyone know how to fix this? I don't want the www.

    (Might this fuck up how google searches the site and register backlinks as well?)

    Jolly
    Last edited by jollyhumper; 02-12-2012, 03:53 AM. Reason: added a question to the end
    MongerCash - This Asian program converts as hell!. Sign up! |

    Tons of Porn
    |
    Email: Jolly [at] pornpitstop (døt) com | Icq: 619 746 889 |
  • brentbacardi
    Confirmed User
    • Nov 2009
    • 1425

    #2
    Look in your .htaccess file

    Redirect www to non-www:
    RewriteEngine On
    RewriteBase /
    RewriteCond %{HTTP_HOST} ^www.yourdomain.com [NC]
    RewriteRule ^(.*)$ http://yourdomain.com/$1 [L,R=301]

    Redirect non-www to www:
    RewriteEngine On
    RewriteBase /
    RewriteCond %{HTTP_HOST} ^yourdomain.com [NC]
    RewriteRule ^(.*)$ http://www.yourdomain.com/$1 [L,R=301]

    You should ALWAYS use one of these redirects everytime! This way search engines know which one you want to use and there is no danger in getting duplicate listings/penalties/etc for two different sites with the exact same content.
    Last edited by brentbacardi; 02-12-2012, 11:13 AM.
    Go Fuck Yourself!

    Comment

    • jollyhumper
      Confirmed User
      • Mar 2011
      • 400

      #3
      Thank you very much!

      Jolly
      MongerCash - This Asian program converts as hell!. Sign up! |

      Tons of Porn
      |
      Email: Jolly [at] pornpitstop (døt) com | Icq: 619 746 889 |

      Comment

      • jollyhumper
        Confirmed User
        • Mar 2011
        • 400

        #4
        However, when I use your code, the browser is sent into a loop, which ends with an error.
        (Error is given in Norwegian, but xtremely loosely translated "the command will never be completed")

        Jolly
        MongerCash - This Asian program converts as hell!. Sign up! |

        Tons of Porn
        |
        Email: Jolly [at] pornpitstop (døt) com | Icq: 619 746 889 |

        Comment

        • jollyhumper
          Confirmed User
          • Mar 2011
          • 400

          #5
          Originally posted by jollyhumper
          However, when I use your code, the browser is sent into a loop, which ends with an error.
          (Error is given in Norwegian, but xtremely loosely translated "the command will never be completed")
          Jolly
          It does work, the code given. I'm not sure where I fucked up, but when I tried again today, it was effortless. GFmyself

          thanks!

          Jolly
          MongerCash - This Asian program converts as hell!. Sign up! |

          Tons of Porn
          |
          Email: Jolly [at] pornpitstop (døt) com | Icq: 619 746 889 |

          Comment

          Working...