Support » Multisite » Upgrading or Installing YD Network-wide Options

Upgrading or Installing YD Network-wide Options

  • I recently moved my site to a new host and I been having problems with the multi site ever since. I originally installed YD Network-wide Options plugin and had a message to upgrade the plugin. When I upgraded I got the following error

    Fatal error: Call to undefined function switch_to_blog() in /home/timeoutb/public_html/wp-content/plugins/yd-wpmu-sitewide-options/yd-wpmu-sitewide-options.php on line 715

    I couldn’t do anything on the site and had to delete the plugin via ftp. I tried installing from scratch but still get the same error.

    Can some please advise if this is the correct plugin for Multi site development and what the problem could be?

Viewing 15 replies - 1 through 15 (of 18 total)
  • Does the site work without the plugin?

    You may need to clean out the database settings and start over with it (I’ve had certain plugins get hinky after a move). Basically though, if it works when you delete the plugin, then it’s a plugin problem, and you may need to wait till the dev gets alerted.

    I’ve tagged this yd-wpmu-sitewide-options so he should be notified.

    The site works ok without the plugin, I followed the instructions from the blog Remove WordPress Multisite data and I then tried to reinstall but I got the same error.

    I’m not 100% sure what u mean clean out the database settings, I deleted the following files from the database;

    I also check the wp-config.php file and can’t see any reference to a multi-site setup

    I also check the wp-config.php file and can’t see any reference to a multi-site setup

    So … you didn’t add define('WP_ALLOW_MULTISITE', true); to your wp-config.php file?

    Those are TABLES in the database, not files, by the way. And if the database settings are per-site, so in wp_options (or wp_1_options) there may be references to the plugin. Then again, if you wiped the whole thing then it’s not that.

    I’m not to sure but I think I sorted the problem out. I copied the references from my old site wp-config to the new config.
    define(‘WP_ALLOW_MULTISITE’, true);
    define( ‘MULTISITE’, true );
    define( ‘SUBDOMAIN_INSTALL’, true );
    $base = ‘/’;
    define( ‘DOMAIN_CURRENT_SITE’, ‘timeoutbookings.co.za’ );
    define( ‘PATH_CURRENT_SITE’, ‘/’ );
    define( ‘SITE_ID_CURRENT_SITE’, 1 );
    define( ‘BLOG_ID_CURRENT_SITE’, 1 );

    I then imported the backup of the tables I had deleted earlier.
    In my plugins I had a plugin which was network activated which I deactivated.

    This seems to have worked and its up and running now, i’ll check to see if everything else is ok.

    Thanks for the help.

    Can ask u also a quick question about referencing a domain name to a sub-domain in a wordpress multi-site, is this possible so that when you type a domain name you are taken to a sub-domain ?

    Yes, but that’s just domain parking, and not a MultiSite thing (unless what you want is for domain.com to transparently become subdomain.domain2.com )

    I want the domain to transparently become subdomain.domain2.com If I park the domain on the hosting site can I set the domain as the subdomain in the wordpress multi site.

    The only other way I can think is of is to redirect it via the index.php but that will still have the subdomain as the URL

    Can ask u also a quick question about referencing a domain name to a sub-domain in a wordpress multi-site, is this possible so that when you type a domain name you are taken to a sub-domain ?

    maybe you;re looking for domain mapping:


    WordPress 3.0: Multisite Domain Mapping Tutorial

    I thought it was to good to be true…..

    When I add a new site I get error when I try accessing the backend or viewing the site, says google can’t find address.

    Any ideas?

    BEFORE you mess around with domain mapping, make sure it works in general 🙂 Always always.

    If Google can’t find the address, then your domain name is probably wrong.

    Before you mess with anything network specific, always make sure the subsites work. 😉

    the domain and site works http://www.timeoutbookings.co.za but the subdomain doesn’t work http://new.timeoutbookings.co.za/

    Did you set up wildcard subdomains as per the network enabling instructions? Did you ask your webhost if they are supported?



    I’m arriving after the battle here, but anyway, just for the records, since a plugin of mine was mentioned:

    The message “Fatal error: Call to undefined function switch_to_blog()” always means you are trying to use networked site-specific features in a non-networked WordPress setup (switch_to_blog() is a WPMU core function: hence if it’s not defined it automatically implies you’re not networked).

    It is not specific to this plugin (although in a future version I might as well have the plugin check if the site is really multisite-enabled upon install!)

    And just to make it very clear, the YD Network Wide Options plugin, as the name implies, has no use whatsoever in a non-networked setup.

    @ipstenu: thanks for the tag, and for pointing in the right direction (site wasn’t even multisite enabled in the first place) – this seems a pretty current mistake.

    @ydubois – You may want to consider a check on activation. “Is MultiSite enabled? No? DIE!”



    @ipstenu: yeah that’s what I said. I’ll do it on next release, but that won’t be soon: I just released a new stable version, I have to work on other stuff before. Anyways here the user switched their site from multisite to standalone without first deactivating plugins, if I understand well. So that means this would have to be checked everytime, not just on first activation. Guess in that case I definitely should switch to more paranoid programming 😉

Viewing 15 replies - 1 through 15 (of 18 total)
  • The topic ‘Upgrading or Installing YD Network-wide Options’ is closed to new replies.