• Resolved communityconnect

    (@communityconnect)


    I’ve moved my multi-site from GoDaddy’s old hosting server where it worked fine, to their new cPanel hosting. Now if I leave the multi-site activation code in wp-config.php I lose my database connection.

    My site url is community-connect.ca

    Here’s the last part of my wp-config.php file when I can connect to the database but don’t have multisite:

    define(‘WP_DEBUG’, false);

    /* That’s all, stop editing! Happy blogging. */

    /** Absolute path to the WordPress directory. */
    if ( !defined(‘ABSPATH’) )
    define(‘ABSPATH’, dirname(__FILE__) . ‘/’);

    /** Sets up WordPress vars and included files. */
    require_once(ABSPATH . ‘wp-settings.php’);

    /* Multisite */
    define(‘WP_ALLOW_MULTISITE’, true);

    If I add the code like this it no longer connects to the database:

    define(‘WP_DEBUG’, false);

    define(‘MULTISITE’, true);
    define(‘SUBDOMAIN_INSTALL’, false);
    define(‘DOMAIN_CURRENT_SITE’, ‘community-connect.ca’);
    define(‘PATH_CURRENT_SITE’, ‘/’);
    define(‘SITE_ID_CURRENT_SITE’, 1);
    define(‘BLOG_ID_CURRENT_SITE’, 1);

    /* That’s all, stop editing! Happy blogging. */

    /** Absolute path to the WordPress directory. */
    if ( !defined(‘ABSPATH’) )
    define(‘ABSPATH’, dirname(__FILE__) . ‘/’);

    /** Sets up WordPress vars and included files. */
    require_once(ABSPATH . ‘wp-settings.php’);

    /* Multisite */
    define(‘WP_ALLOW_MULTISITE’, true);

    I tried taking out the last line of code but that didn’t make any difference.

Viewing 15 replies - 1 through 15 (of 18 total)
  • Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    ?????? Advisor and Activist

    The database connection details didn’t change, did they?

    Thread Starter communityconnect

    (@communityconnect)

    I didn’t change anything else and the single site version has a connection to the database – it’s only when I add the multisite code that I lose the database connection

    Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    ?????? Advisor and Activist

    What happens if you do without this line: define('MULTISITE', true);

    Thread Starter communityconnect

    (@communityconnect)

    One other odd thing – I can’t see my .htaccess file in the file manager – it’s like it goes away once I’ve had the error. Is that possible or is it just invisible?

    Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    ?????? Advisor and Activist

    Invisible. And don’t use the cPanel file manager, get a real FTP app ?? You’ll be happier.

    Thread Starter communityconnect

    (@communityconnect)

    same problem – I lose my database connection even if I don’t include

    define(‘MULTISITE’, true);

    Thread Starter communityconnect

    (@communityconnect)

    I used dreamweaver to move the site – I’ve just been playing around with the wp-config.php file on the file manager so I don’t have to keep transferring it back and forth.

    Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    ?????? Advisor and Activist

    I was going to ask HOW you moved the site ?? Just copy paste of the files?

    How old was this site? Was it WPMU upgraded to WP Multisite?

    Thread Starter communityconnect

    (@communityconnect)

    I just downloaded the files from my old server with ftp and then uploaded them to the new site, same with the database – then imported the database using phpmyadmin. I looked at plugins to migrate the site but couldn’t find any that were compatible with multisite.

    The site was created about a year ago and I just upgraded to multisite through the admin panel. I didn’t do the upgrade with WPMU but I’m a member and am using a child theme of one of their themes and some of their plugins (all of which are deactivated at the moment).

    I still have the site on the old server but had to move the domain over in order to begin adapting the site to the new location.
    My original install was in a sub-folder of an existing html site which I’m retiring in favour of an entirely WordPress site (if I can get it to work). I took the opportunity when moving the site to move it out of the sub-folder which means I have some custom menus and links to fix as well ??

    Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    ?????? Advisor and Activist

    I just upgraded to multisite through the admin panel

    Through … WordPress’s admin panel or GoDaddy’s? If it’s the latter, you need to talk to them because I got no idea what they did there (but there HAVE been weird issues).

    Thread Starter communityconnect

    (@communityconnect)

    Originally I did it through the WordPress admin panel but after the site was moved I couldn’t connect to the admin panel so I got a GoDaddy tech involved to fix the link to the database – in the process he deactivated multisite. I could then get in the admin panel and update permalinks but when he tried to re-activate multisite I lost it again – you know the rest… I’m not really sure what he did on his end so I guess I will have to get them involved again. My reluctance is that I haven’t found one that knows anything about multisite.

    Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    ?????? Advisor and Activist

    Rewind.

    You put this at the BOTTOM of your wp-config.

    /* Multisite */
    define('WP_ALLOW_MULTISITE', true);

    Re-read that file. See where it says /* That's all, stop editing! Happy blogging. */

    That means stop editing ?? Pyut that Multisite line up with the other multisite lines ??

    Thread Starter communityconnect

    (@communityconnect)

    I didn’t put that there THEY DID! I noticed it yesterday and tried taking it out when I inserted the code from my admin panel but it still didn’t work. I’ll try just moving it up and see what that does. Thanks.

    Thread Starter communityconnect

    (@communityconnect)

    So – I’ve got this far:

    */
    define('WP_DEBUG', false);
    /* Multisite */
    define('WP_ALLOW_MULTISITE', true);
    define('MULTISITE', true);
    define('SUBDOMAIN_INSTALL', false);
    define('DOMAIN_CURRENT_SITE', 'community-connect.ca');
    
    /* That's all, stop editing! Happy blogging. */
    
    /** Absolute path to the WordPress directory. */
    if ( !defined('ABSPATH') )
    	define('ABSPATH', dirname(__FILE__) . '/');
    
    /** Sets up WordPress vars and included files. */
    require_once(ABSPATH . 'wp-settings.php');

    at this stage everything still shows up from my main site but it still hasn’t activated multisite.

    If I add the next line or lines of code:

    define('PATH_CURRENT_SITE', '/');
    define('SITE_ID_CURRENT_SITE', 1);
    define('BLOG_ID_CURRENT_SITE', 1);

    Then I lose the database connection.

    Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    ?????? Advisor and Activist

    *shakes fist at GoDaddy and tells on them*

Viewing 15 replies - 1 through 15 (of 18 total)
  • The topic ‘moved multi-site won't establish database connection if I activate in ip-config’ is closed to new replies.