WordPress.org

Ready to get started?Download WordPress

Forums

Cleaner Gallery
PHP warning (4 posts)

  1. Cibulka
    Member
    Posted 2 years ago #

    Hi, after activating great CLEANER GALLERY plugin, I recieved a PHP warning.

    "Warning: Creating default object from empty value in XXX\wp-content\plugins\cleaner-gallery\cleaner-gallery.php on line 84"

    Apparently I am not the only one having this problem: http://www.google.cz/search?q=cleaner+gallery+default+object+warning

    Any sollutions? I'm no PHP guru, so please go easy on me. :) Thanks!

    http://wordpress.org/extend/plugins/cleaner-gallery/

    [ Please do not bump, that's not permitted here. ]

  2. peterjanes
    Member
    Posted 1 year ago #

    You can work around the warning by adding this at line 83 (for plugin version 0.9.2):

    if ( !$cleaner_gallery ) {
                    $cleaner_gallery = new stdClass;
            }

    All it does is create an instance of an empty object that the settings will be cached in, if it doesn't already exist.

  3. supernova1
    Member
    Posted 1 year ago #

    Didn't work

    The error disappeared, but the images don't appear.

  4. peterjanes
    Member
    Posted 1 year ago #

    Haven't seen that behaviour, but I can't see any way it would be related to the warning (or the fix for it): all the cleaner_gallery_get_setting method does is cache the settings that were in the database. You might want to start a new topic, though, since it's a different bug than what you reported above.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic