1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

need help redirect 301 with .htaccess to blogspot

Discussion in 'Blogging' started by itiljebleh, Oct 20, 2013.

  1. itiljebleh

    itiljebleh Newbie

    Joined:
    Apr 2, 2013
    Messages:
    25
    Likes Received:
    4
    hi guys...
    guys i need some help here for setting up redirection on my migrated domain to blogspot

    so my previous website has 2 structure
    www,domain.c0m is static html website with and w ww.domain.c0m /blog/ which is wordpress platform with lot of pages some of the pages is still has nice backlink pointing to the blogpost but its showed me 404 on my webmastertool

    i managed to 301 my main domain but the /blog/ get me 404 error or error 500, im hosting my previous domain on hostgator and my new site that i want to keep is on blogspot..how do i setup properly the htacess?

    thanks guys
     
  2. IamNRE

    IamNRE Jr. VIP Jr. VIP Premium Member

    Joined:
    Aug 18, 2010
    Messages:
    4,663
    Likes Received:
    7,108
    Occupation:
    Generate Leads With FB Ads For Just $1
    Home Page:
    You need to add the code to the blog folder as well.

    You created a subfolder called "blog" right?

    Add the code there.

    Or do this in WP:


    c)Go to appearance
    d)Go to editor
    e)Go to header.php
    f)Put the following piece of code as the FIRST line before any of the other codes then save changes:
    -make sure to change the "http://www.new-url.com" to your money site that you are trying to rank.

    Code:
    [/COLOR][COLOR=#FFFFCC]<?[/COLOR]
    Header( "HTTP/1.1 301 Moved Permanently" );
    Header( "Location: http://www.new-url.com" ); [COLOR=#FFFFCC]?>[/COLOR][COLOR=#FFFFCC]
    Thanks to bobbylove
     
  3. itiljebleh

    itiljebleh Newbie

    Joined:
    Apr 2, 2013
    Messages:
    25
    Likes Received:
    4
    hi IamNREIamNRE thank for your reply

    yes ,but the wp instalation on my /blog/ folder allready deleted so the post who allreday has backlink on it ponting to 404 error on my blogspot..on my hostgator domain only has an single htaccess file...

    should i recreate blog folder and install blank wordpress and follow you step you mention above?
     
  4. IamNRE

    IamNRE Jr. VIP Jr. VIP Premium Member

    Joined:
    Aug 18, 2010
    Messages:
    4,663
    Likes Received:
    7,108
    Occupation:
    Generate Leads With FB Ads For Just $1
    Home Page:
    Erhm.... I dunno to be honest.

    I'm not really a super geek. But if I were you I'd probably just re-create the subfolder and add a HTML redirect (not install the WP again tho).