WordPress.org

Ready to get started?Download WordPress

Forums

Multisite Language Switcher
Some PHP warnings when debug enabled (6 posts)

  1. eugenious
    Member
    Posted 10 months ago #

    Hello, just to let you know, using WordPress in debugging mode by enabling "define('WP_DEBUG', true);" in wp-config.php, I came across some php warnings when using the MSLS plugin. I'm using PHP 5.4.

    The warnings are:
    Strict Standards: call_user_func_array() expects parameter 1 to be a valid callback, non-static method MslsPlugin::init_widget() should not be called statically in /Users/ehuang/Documents/apache-doc-root/wordpress/wp-includes/plugin.php on line 406

    Strict Standards: Accessing static property MslsRegistry::$arr as non static in /Users/ehuang/Documents/apache-doc-root/wordpress/wp-content/plugins/multisite-language-switcher/includes/MslsRegistry.php on line 42

    Strict Standards: Accessing static property MslsRegistry::$arr as non static in /Users/ehuang/Documents/apache-doc-root/wordpress/wp-content/plugins/multisite-language-switcher/includes/MslsRegistry.php on line 52

    Strict Standards: Static function MslsMain::init() should not be abstract in /Users/ehuang/Documents/apache-doc-root/wordpress/wp-content/plugins/multisite-language-switcher/includes/MslsMain.php on line 24

    They are fixed easily enough. If you need more details I can send you some.

    Great plugin by the way.

    http://wordpress.org/plugins/multisite-language-switcher/

  2. realloc
    Member
    Plugin Author

    Posted 10 months ago #

    Thanks for your message. My working copy here runs on a system which has debug mode activated. So the new version will not produce warnings like this.

    Cheers,
    Dennis.

  3. eugenious
    Member
    Posted 10 months ago #

    Ok, that's great.

    In case you haven't seen this yet, I got another debug message after editing a page:
    Notice: Undefined offset: 0 in /Users/ehuang/Documents/apache-doc-root/wordpress/wp-includes/capabilities.php on line 1070

    This is coming from MslsMetaBox.php
    this:
    if ( !current_user_can( 'edit_page' ) )
    should be replaced with:
    if ( !current_user_can( 'edit_page', $post_id ) ) {

  4. jaime8111
    Member
    Posted 9 months ago #

    Hello and thanks for this plugin. I have the same error, when do you plan to release the new version?
    I need to go to production this week, and now the plugin is not working.
    Thanks!

  5. realloc
    Member
    Plugin Author

    Posted 9 months ago #

    @jaime8111 Please set the error reporting to E_ALL ^ E_NOTICE in production. These are just warnings so there is nothing that should bring you to the conclusion that the plugin is not working.

    The next version comes in the next weeks.

    Cheers,
    Dennis.

  6. Eric Holmes
    Member
    Posted 9 months ago #

    I was just about to report this as well. Glad to see you are on top of this realloc! :)

Reply

You must log in to post.

About this Plugin

About this Topic

Tags