• Ok, here is the situation.

    I am sharing hosting with my sites. My main site is set up and hosting all my other domains. I have each of these domains pointed to a subdirectory on the main site. For example:

    mainsite.com is hosting mainsite.com/domainA, mainsite.com/domainB, etc.

    I have a domain that was pointing to mainsite.com/domainA which had WordPress on it. I want to shift that domain to point to mainsite.com/domainB, which also has WordPress installed on it but WP 3.0.1 (using the multisite functionality and buddypress).

    So, I went into my host, pointed the domain to mainsite.com/domainB and indeed, when you type in the domain name it redirects to mainsite.com/domainB.

    Problem is, I don’t want my URL to reveal where I am hosting my site to visitors. I don’t want the url to say mainsite.com/domainB. I want the URL to say domain.com.

    With the old WordPress, or even the current standard install (not multisite), you would just go to Admin > Settings > General and change the URLs of the WordPress URL and Site URLs. (as per our example, I just changed it from mainsite.com/domainA to domain.com)

    You can’t do this in WP 3.0 multisite. I am trying to figure out how. Now, when I look at the wp-config.php file I see:

    define( 'MULTISITE', true );
    define( 'SUBDOMAIN_INSTALL', false );
    $base = '/domainA/';
    define( 'DOMAIN_CURRENT_SITE', 'mainsite.com' );
    define( 'PATH_CURRENT_SITE', '/domainA/' );
    define( 'SITE_ID_CURRENT_SITE', 1 );
    define( 'BLOG_ID_CURRENT_SITE', 1 );

    Is that what I need to change? Just change mainsite.com to domain.com and domainA to domainB?

    Thanks to anyone who can help!

Viewing 4 replies - 16 through 19 (of 19 total)
  • @halles Thank you, thank you, thank you! I lost about 5 hrs of sleep trying to figure this out. Hopefully my experience helps others avoid some aggravation.

    I followed www.ads-software.com’s directions without any luck. It’s not complete and parts are totally wrong for 3.0 multisite. The General Tab does not have a URL box you can change, so I had to go into phyMyAdmin and manually find all instances of my old install (/dev/.. i wanted it moved to root).

    Moved files to root, changed DB. Site switched over, but couldn’t login. Wrong passwords yielded the usual No-No shake, but correct passwords just sent me back to the admin login page in an endless loop. Editing wp-config.php define( 'PATH_CURRENT_SITE', '/' ); caused a database connection error. I then tried messing with .htaccess and mod_rewrite directives w/o success.

    I didn’t think to look in wp_blogs. I zapped my old ‘dev’ from the following tables, changing it to ‘/’:

    wp_site (field: path)
    wp_options (field: siteurl, home)

    then in .htaccess, I changed
    RewriteBase ‘/dev/’ to RewriteBase /

    Wow… all that.. and only my main site is restored. Networked sites still need working.

    Update: ok, finally figuring this all out.
    i need to keep RewriteBase /

    Then Wp admin lets me change their siteurls. If this is locked for you, you’ll need to go into phpMyAdmin and edit the table for each blog, ex:

    wp_3_options is the options table for my 3rd blog. Change siteurl to the new path.

    I followed www.ads-software.com’s directions without any luck. It’s not complete and parts are totally wrong for 3.0 multisite. The General Tab does not have a URL box you can change, so I had to go into phyMyAdmin and manually find all instances of my old install (/dev/.. i wanted it moved to root).

    If you;re talking about a codex entry, you should point out which one. Likely it was written for single installs.

    You are free to edit or add to the codex as a member, anyone can.

Viewing 4 replies - 16 through 19 (of 19 total)
  • The topic ‘Migrate WP 3.0 from subdomain to another subdomain’ is closed to new replies.