WordPress.org

Ready to get started?Download WordPress

Forums

WordPress SEO by Yoast
[resolved] 'wp_0_options' error on multisite (5 posts)

  1. Hi,

    On a site that used to be running WPMU before the WP 3.0 release, when in wp-admin, wpseo_admin_bar_menu() is throwing SQL errors. Using WordPress SEO v1.1.2.

    WordPress database error Table 'mydbtable.wp_0_options' doesn't exist for query SELECT * FROM wp_0_options WHERE option_name = 'siteurl' made by require_once, do_action, call_user_func_array, wp_admin_bar_render, do_action_ref_array, call_user_func_array, wpseo_admin_bar_menu, get_admin_url, get_site_url, get_blog_option

    I fixed this in wpseo_admin_bar_menu() by changing get_admin_url() to network_admin_url().

    http://wordpress.org/extend/plugins/wordpress-seo/

  2. diesel12
    Member
    Posted 2 years ago #

    Hmmmm. Seeing this error as well on a multisite install.

    Looks like this might have the cause:

    http://seo-wordpress.com/paul-gibbs-on-plugin-wordpress-seo-by-yoast-wp_0_options-error-on-multisite/

  3. FlashUK
    Member
    Posted 2 years ago #

    Actually, taking a closer look, the solution isn't correct.

    According to the documentation, Yoast has not used the function correctly.
    http://codex.wordpress.org/Function_Reference/get_admin_url

    File: wordpress-seo/inc/wpseo-non-ajax-functions.php
    Line: 122

    His code is:
    get_admin_url('admin.php?page=wpseo_dashboard')

    A value must be set for the first parameter. The correct code is:
    get_admin_url(null, 'admin.php?page=wpseo_dashboard')

    This will stop the unnecessary error occurring.

    Yoast, I hope you see this - Thanks.

  4. James Collins
    Member
    Posted 2 years ago #

    I have just come across this issue as well.

    I think he should be using admin_url() instead of get_admin_url().

    admin_url() is just a simple wrapper function that calls get_admin_url() anyway.

  5. Joost de Valk
    Member
    Plugin Author

    Posted 1 year ago #

    Missed this one, and don't know why. Just committed the fix to trunk, will be in the next release.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic