301 Redirect to Different Domain & Different Folder

Discussion in 'Site & Server Administration' started by domainer_10, Jul 12, 2008.

  1. #1
    I know how to redirect through a 301 and htacess on apache linux server to a different domain. However, Im having trouble figuring out how to redirect my blog to not only a different domain but ALSO a different folder. I want my blog to redirect from the root to a blog directory on the new domain.



    I want to go from http://www.domain1.com/blogpost1/


    to


    http://www.domain2.com/blog/blogpost1/


    Anyone know how to do that? Thanks.
     
    domainer_10, Jul 12, 2008 IP
  2. wattie

    wattie Peon

    Messages:
    23
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #2
    Just post the following code inside the "blogpost1" folder of domain1.com:

    
    Redirect 301 / http://www.domain2.com/blog/blogpost1/
    
    Code (markup):
     
    wattie, Jul 16, 2008 IP
  3. livedomainsearch

    livedomainsearch Peon

    Messages:
    111
    Likes Received:
    3
    Best Answers:
    0
    Trophy Points:
    0
    #3
    I think you can do this by modifying your domain setting as well, like the MX record and Zone file -- I am not 100 % sure but I think you can.
     
    livedomainsearch, Jul 16, 2008 IP
  4. livedomainsearch

    livedomainsearch Peon

    Messages:
    111
    Likes Received:
    3
    Best Answers:
    0
    Trophy Points:
    0
    #4
    livedomainsearch, Jul 16, 2008 IP
  5. domainer_10

    domainer_10 Peon

    Messages:
    1,720
    Likes Received:
    24
    Best Answers:
    0
    Trophy Points:
    0
    #5
    Thanks for the help guys, but no longer needed. I decided to not do this and just have a get a new domain for a new site and keep the old one on its current one.
     
    domainer_10, Jul 16, 2008 IP