1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

How To Move My WP Blog From Subdomain To Root?

Discussion in 'WordPress' started by Galaxyl, Sep 3, 2007.

  1. #1
    I need to move a WordPress blog to a new host, and at the same time I would like to move it from the subdomain where it currently is, to the main directory of the same domain.

    I assume moving from one host to another is simple - just do a backup, switch DNS, install WP with Fantastico on new host, and then restore the backup .. is that right?

    But what about putting it in the main directory instead of the subdomain? Will that mess up all the internal linking of the old posts, categories etc in the database?

    :confused:

    Gal
     
    Galaxyl, Sep 3, 2007 IP
  2. bschneider5

    bschneider5 Active Member

    Messages:
    1,009
    Likes Received:
    44
    Best Answers:
    0
    Trophy Points:
    88
    #2
    I wouldn't think it would be that big a deal, just a matter of re-installing wordpress then using the same DB.
     
    bschneider5, Sep 3, 2007 IP
  3. sat123

    sat123 Banned

    Messages:
    1,600
    Likes Received:
    45
    Best Answers:
    0
    Trophy Points:
    0
    #3
    That's ok but from domain to subdomain i think we have to change any settings in wp..else it may screw.....perhaps in option under site url put the domain name and under wordpress url put the domainname/blog . Even i'm not sure.
     
    sat123, Sep 4, 2007 IP
  4. adultuserbars

    adultuserbars Peon

    Messages:
    762
    Likes Received:
    8
    Best Answers:
    0
    Trophy Points:
    0
    #4
    Basically all you need to do is restore the database in the new location where you are going to host the blog, BUT you also need to change the WordPress address, and blog address in the WP Control Panel at the new setup, if you are confident you and change it using phpMyAdmin, or you have to change it through the control panel on the new site.

    PM me it you would like some more help in doing it, else send me a PM and I can do it for you, it only takes about 2minutes.
     
    adultuserbars, Sep 4, 2007 IP
  5. wowhaxor

    wowhaxor Banned

    Messages:
    1,507
    Likes Received:
    36
    Best Answers:
    0
    Trophy Points:
    0
    #5
    put the database in root directory (with index.php also i think) then in wordpress control panel thing set the destination to root.
     
    wowhaxor, Sep 4, 2007 IP
  6. web-developer

    web-developer Member

    Messages:
    77
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    41
    #6
    I know this thread is very old but may be this is useful to other people.
    I found this url by searching to solution so I think add reply may this is helpful.

    If you want to change the all URL from you database so may be this helpful to you.

    UPDATE wp_options SET option_value = replace(option_value, ‘http://dev.your_domain_name.com’, ‘http://www.your_domain_name.com’) WHERE option_name = ‘home’ OR option_name = ‘siteurl’;

    UPDATE wp_options SET option_value = replace(option_value, ‘http://dev.your_domain_name.com’, ‘http://www.your_domain_name.com’) WHERE option_name = ‘home’ OR option_name = ‘siteurl’;

    UPDATE wp_posts SET guid = replace(guid, ‘http://dev.your_domain_name.com’,’http://www.your_domain_name.com’);
    UPDATE wp_posts SET post_content = replace(post_content, ‘http://dev.your_domain_name.com’, ‘http://www.your_domain_name.com’);
     
    web-developer, Jul 10, 2011 IP