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

Help!! Google has indexed 2 versions of my site!!!

Discussion in 'Black Hat SEO' started by Moogle!, Aug 20, 2011.

  1. Moogle!

    Moogle! Regular Member

    Joined:
    Dec 27, 2010
    Messages:
    349
    Likes Received:
    52
    Location:
    Pearl of the Orient
    One with a www and another one with no www!

    I have already set the preferred domain for both of them to use www on the google webmaster tools, but both versions are still indexed!

    What should I do?

    Edit:
    It's a wordpress site btw and I have selected to use www on my wp settings.
     
    Last edited: Aug 20, 2011
  2. chipmunk951

    chipmunk951 Senior Member

    Joined:
    May 10, 2010
    Messages:
    1,011
    Likes Received:
    443
    Occupation:
    IM
    Location:
    Zimbabwe
    301 redirect on your root folder or!

    basically just edit the .htaccess to redirect one version to the other.

    Here's what mine look like. You can use this :)

    redirect 301 http://version of site you don't want http://the one you want
    <IfModule mod_suphp.c>
    suPHP_ConfigPath /home/xxx/public_html/xxx/php.ini
    <Files php.ini>
    order allow,deny
    deny from all
    </Files>
    </IfModule>

    # BEGIN WordPress
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteRule ^index\.php$ - [L]
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    </IfModule>

    # END WordPress
     
    • Thanks Thanks x 1
  3. wpbacklinks

    wpbacklinks Jr. VIP Jr. VIP Premium Member

    Joined:
    Mar 27, 2010
    Messages:
    3,397
    Likes Received:
    1,339
    Gender:
    Male
    Occupation:
    Affiliate Marketer
    Location:
    Everywhere
    Ooops,, my wrong.. lol
     
    Last edited: Aug 20, 2011
  4. NapsteR

    NapsteR Jr. VIP Jr. VIP

    Joined:
    Mar 2, 2011
    Messages:
    2,779
    Likes Received:
    2,374
    Occupation:
    Full Time IMer
    Location:
    http://www.seophd.com
    if its wordpress, it should have 301 redirection in default. correct me if i'm wrong..
     
  5. tiagorossi

    tiagorossi Junior Member

    Joined:
    Aug 2, 2011
    Messages:
    150
    Likes Received:
    43
    ì have a problem also, i backlinking a subdomain wp blog but google just indexed the domain.com/wp
    i use hostgator with cpanel and dont know why it happen
     
  6. Moogle!

    Moogle! Regular Member

    Joined:
    Dec 27, 2010
    Messages:
    349
    Likes Received:
    52
    Location:
    Pearl of the Orient
    (at) chipmunk, Thanks! but I'm not sure how to implement that code on my site. Is there a wordpress plugin that will do this automatically?
     
  7. gialappas

    gialappas Regular Member

    Joined:
    Jan 25, 2010
    Messages:
    263
    Likes Received:
    180

    Access to your website via FTP
    in the main folder there are a file called .htaccess
    click on EDIT and add this code (don't delete anything,just add)

    redirect 301 http://yourwebsite.com http://www.yourwebsite.com
     
  8. kytro3601

    kytro3601 Newbie

    Joined:
    Aug 20, 2011
    Messages:
    22
    Likes Received:
    4
    Like everyone has suggested a 301 redirect would be the best thing to do.