Results 1 to 12 of 12

Thread: 301 Redirect ?

  1. #1
    chaosicq's Avatar
    chaosicq is offline Private Member
    Join Date
    August 2008
    Location
    malvern
    Posts
    88
    Thanks
    2
    Thanked 4 Times in 4 Posts

    Default 301 Redirect ?

    Hi
    I want to redirect one sites entire domain content to another new domain for a permanent move, but I would like it if when the uses clicks on the old domain that the redirect is automatic instead having to click on a link to get to the new site, Is there anything I can add to make this happen?.

    HTTP/1.1 301 Moved Permanently
    Location: http://www.blablabla.com/
    Content-Type: text/html
    Content-Length: 174
    <html>
    <head>
    <title>Moved</title>
    </head>
    <body>
    <h1>Moved</h1>
    <p>This page has moved to <a href="http://www.blablabla.com/">http://www.blablabla.com/</a>.</p>
    </body>
    </html>
    I did not ! ask for this life it was forced upon me !! How ever i know when to hold up know when to fold up and i know when to walk away


    Home Poker
    Party Poker Bonus Codes
    Texas Holdem Poker
    Poker Codes
    Party Casino
    Affiliate Programs Reputable

  2. #2
    GFPC is offline Private Member
    Join Date
    April 2008
    Location
    Everywhere
    Posts
    3,520
    Blog Entries
    1
    Thanks
    1,150
    Thanked 1,034 Times in 674 Posts

    Default

    Do the code in your .htaccess file

    Create a .htaccess file in the root of the domain and add his code

    RedirectMatch 301 (.*) http://www.blahblah/

    All indexd pages in google will direct to the homepage of the new site.

    That is one way to do it

    (note) - when you hand over the domain to them - they could remove the redirect by the way.
    Last edited by GFPC; 17 November 2010 at 4:13 pm.

  3. The Following User Says Thank You to GFPC For This Useful Post:

    chaosicq (17 November 2010)

  4. #3
    chaosicq's Avatar
    chaosicq is offline Private Member
    Join Date
    August 2008
    Location
    malvern
    Posts
    88
    Thanks
    2
    Thanked 4 Times in 4 Posts

    Default

    Quote Originally Posted by GFPC View Post
    Do the code in your .htaccess file

    Create a .htaccess file in the root of the domain and add his code

    RedirectMatch 301 (.*) http://www.blahblah/

    All indexd pages in google will direct to the homepage of the new site.

    That is one way to do it

    (note) - when you hand over the domain to them - they could remove the redirect by the way.

    Thanks for the help, Yes they can change it, but this will give me time to migrate the site and not lose search engine positions e.c.t .
    I did not ! ask for this life it was forced upon me !! How ever i know when to hold up know when to fold up and i know when to walk away


    Home Poker
    Party Poker Bonus Codes
    Texas Holdem Poker
    Poker Codes
    Party Casino
    Affiliate Programs Reputable

  5. #4
    GFPC is offline Private Member
    Join Date
    April 2008
    Location
    Everywhere
    Posts
    3,520
    Blog Entries
    1
    Thanks
    1,150
    Thanked 1,034 Times in 674 Posts

    Default

    no problem mate. i understand! Glad i could help a little.

    I just checked - it seems to work fine.

    One thing though -- all indexed pages from google will land
    on that homepage by the way.

  6. #5
    Renee's Avatar
    Renee is offline Sponsor Affiliate Program
    Join Date
    August 2005
    Posts
    9,072
    Blog Entries
    6
    Thanks
    6,642
    Thanked 3,543 Times in 2,206 Posts

    Default

    If you want google to reindex your new site so that all the pages redirect to their relevant page on the new site, you'll need to add all the pages and their 301 redirects to the htaccess file..

    IMO this is definitely the way to go.

    Good luck
    __________________
    Renee, Affiliate Program Manager
    http://www.RewardsAffiliates.com
    Affiliate Program for CasinoRewards.com
    Best Affiliate Manager - CAP Awards 2008
    Best Casino Affiliate Manager - CAP Awards 2009
    Best Casino Affiliate Manager - iGB Affiliate Awards 2010

  7. #6
    GFPC is offline Private Member
    Join Date
    April 2008
    Location
    Everywhere
    Posts
    3,520
    Blog Entries
    1
    Thanks
    1,150
    Thanked 1,034 Times in 674 Posts

    Default

    Agreed. I think all urls will need to be the same though.

    For example - if you want to move http:/www/blah/review.html

    The new site would need the url to be http://www/blah2/review.html


    If he had 100s of pages it can be time consuming.

    Looking at what he is doing - it seems he is just pointing his site to the new one so all his traffic goes to the new site which has similar pages but not exact.

    Doing this on a new domain for sure could work no problem

    Quote Originally Posted by Renee View Post
    If you want google to reindex your new site so that all the pages redirect to their relevant page on the new site, you'll need to add all the pages and their 301 redirects to the htaccess file..

    IMO this is definitely the way to go.

    Good luck

  8. The Following User Says Thank You to GFPC For This Useful Post:

    Renee (22 November 2010)

  9. #7
    best.hands is offline Public Member
    Join Date
    July 2010
    Posts
    275
    Thanks
    1
    Thanked 36 Times in 32 Posts

    Default

    Quote Originally Posted by GFPC View Post
    Agreed. I think all urls will need to be the same though.

    For example - if you want to move http:/www/blah/review.html

    The new site would need the url to be http://www/blah2/review.html


    If he had 100s of pages it can be time consuming.
    Provided that everything is identical except the domain name, redirection of everything (every page) can simply be done with this code below:

    redirect 301 / http://www.newdomain.com/

    Where the / right after 301 indicates a top level redirection. This will only work perfectly though when you're using the same folder structures and filenames with the new site as the old site.

  10. The Following User Says Thank You to best.hands For This Useful Post:

    Renee (22 November 2010)

  11. #8
    GFPC is offline Private Member
    Join Date
    April 2008
    Location
    Everywhere
    Posts
    3,520
    Blog Entries
    1
    Thanks
    1,150
    Thanked 1,034 Times in 674 Posts

    Default

    Let me ask you then if i may. I am curious!

    Say you have an IP - ex 123.45.67
    and domain name abcdefg.com

    the domain works fine but the Ip does not. The IP is at the root. The domain in a folder accesssed by the root.

    How can you create a .htaccess file that makes the urls look like this.

    123.45.67/any-url.com

    Where all the domain ulrs will now be read with the ip infront?

    Quote Originally Posted by best.hands View Post
    Provided that everything is identical except the domain name, redirection of everything (every page) can simply be done with this code below:

    redirect 301 / http://www.newdomain.com/

    Where the / right after 301 indicates a top level redirection. This will only work perfectly though when you're using the same folder structures and filenames with the new site as the old site.

  12. #9
    best.hands is offline Public Member
    Join Date
    July 2010
    Posts
    275
    Thanks
    1
    Thanked 36 Times in 32 Posts

    Default

    Quote Originally Posted by GFPC View Post
    Let me ask you then if i may. I am curious!

    Say you have an IP - ex 123.45.67
    and domain name abcdefg.com

    the domain works fine but the Ip does not. The IP is at the root. The domain in a folder accesssed by the root.

    How can you create a .htaccess file that makes the urls look like this.

    123.45.67/any-url.com

    Where all the domain ulrs will now be read with the ip infront?
    That's a pretty much complicated case which I haven't faced before. But let me try to provide you a good answer.

    As far as my understanding is concern with a web host cpanel and dns management, you may not need to use a .htaccess with it, but a proper filename and folder structure within your webspace. Do it like this,

    - 123.45.67 pointing to the root.
    - A folder in the root dir should be named as the domain name. For instance, if you have domain1.com, a folder in the root named domain1.com should exist as well.
    - Configure domain1.com domain to use another IP that is also pointing to the same webspace as 123.45.67.
    - Configure domain1.com to point to its folder in the root dir.
    - all set and you're done.

    When done properly, 123.45.67/domain1.com should work as well as domain1.com domain.

    Moreover, the reason why this "123.45.67/any-url.com" did not work in the current case you have, I think, because the domain abcdefg.com might be using the IP 123.45.67 and is assigned a folder in the root dir where the IP was set. In this case, accessing 123.45.67/abcdefg.com would return an error since the actual path behind it would look like 123.45.67/abcdefg.com/abcdefg.com where the folder "abcdefg.com" within the "abcdefg.com" folder does not exist.

    If that looks confusing, let's have it this way, abcdefg.com = 123.45.67 and is representing an actual path 123.45.67/abcdefg.com/ based on the configuration done. If you are to dial this actually path in the address bar of your browser, you are actually trying to access 123.45.67/abcdefg.com/abcdefg.com/ much like access this abcdefg.com/abcdefg.com/

    A cure to this case without using another IP is to duplicate the entire folder the domain is pointing to and storing it within the same folder. But this will result to an awkward case where abcdefg.com/abcdefg.com/ and 123.45.67/abcdefg.com/ are both accessible.

    Hope that helps.

  13. #10
    chaosicq's Avatar
    chaosicq is offline Private Member
    Join Date
    August 2008
    Location
    malvern
    Posts
    88
    Thanks
    2
    Thanked 4 Times in 4 Posts

    Default

    One thing that nobody mentioned which I have also done change the google tools account for the website to point to the new one.

    As shown here : http://www.google.com/support/webmas...er=83105&hl=en
    I did not ! ask for this life it was forced upon me !! How ever i know when to hold up know when to fold up and i know when to walk away


    Home Poker
    Party Poker Bonus Codes
    Texas Holdem Poker
    Poker Codes
    Party Casino
    Affiliate Programs Reputable

  14. The Following User Says Thank You to chaosicq For This Useful Post:

    Renee (22 November 2010)

  15. #11
    GFPC is offline Private Member
    Join Date
    April 2008
    Location
    Everywhere
    Posts
    3,520
    Blog Entries
    1
    Thanks
    1,150
    Thanked 1,034 Times in 674 Posts

    Default

    It sounds a bit confusing to me.. Let me explain my issue.

    I have now 8 dedicated IPS all point to the same root folder.

    In the root folder i have folders for each site.

    Ex:

    IP

    123
    124
    125
    126
    127
    128
    ect ect

    All these are pointing to the same root!

    In that root have folder

    abc
    def
    ghi
    jkl
    mno
    pqr
    ect ect

    When i type any of the Ips i get 403 errors.

    I want each ip to go direct to folder of the domain so it looks like this.

    123/abc
    124/def
    125/ghi
    126/jkl
    ect ect

    It i do a 301 the 123, 124,125 dissappears.

  16. #12
    satya is offline Private Member
    Join Date
    May 2007
    Location
    New Delhi
    Posts
    174
    Thanks
    38
    Thanked 54 Times in 38 Posts

    Default

    If I have to move xxhttp://www.olddomain.comxx to xxhttp://www.newdomain.comxx, I just have to include the code
    redirect 301 / http://www.newdomain.com/ in the htaccess file and all follow the same dir & folder structure, all pages will be redirected fine? Plus the website will not lose the google rankings??

    Quote Originally Posted by best.hands View Post
    Provided that everything is identical except the domain name, redirection of everything (every page) can simply be done with this code below:

    redirect 301 / http://www.newdomain.com/

    Where the / right after 301 indicates a top level redirection. This will only work perfectly though when you're using the same folder structures and filenames with the new site as the old site.
    Cheers!
    ----------------------------------------------------------------------
    http://in.linkedin.com/in/satyamahapatra

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •