Forum Replies Created

Viewing 1 replies (of 1 total)
  • Hey,

    Reset/Re-initialize did it for me. The problem appears to be in the initial settings after plugin activation. You can, probably, reproduce this “bug” if the plugin is installed on a fresh WP site (i.e. no database entries for it’s options). If you have error reporting for development you’ll notice a ton of ‘undefined variable’ messages on the plugin’s settings page after activation. It appears that the default options are not set.
    A quick look at ‘init.class.php’, more specifically line 33, reveals that the default options will never be initialized on activation since $lightboxPlusOptions is always set. The following might be a potential fix:>>>
    diff –git a/wp-content/plugins/lightbox-plus/classes/init.class.php b/wp-content/plugins/lightbox-plus/classes/init.class.php
    index f1777c3..49541de 100644
    — a/wp-content/plugins/lightbox-plus/classes/init.class.php
    +++ b/wp-content/plugins/lightbox-plus/classes/init.class.php
    @@ -16,7 +16,8 @@
    */
    function lightboxPlusInit( ) {
    global $g_lightbox_plus_url;
    – $lightboxPlusOptions = get_option(‘lightboxplus_options’);
    + $lightboxPlusOptions = get_option(‘lightboxplus_options’, FALSE);
    + $lightboxPlusOptionsExist = (bool) $lightboxPlusOptions;

    /**
    * Remove following line after a few versions or 2.6 is the prevelent version
    @@ -30,7 +31,7 @@
    *
    * @var wp_lightboxplus
    */
    – if (!isset($lightboxPlusOptions) || isset($_POST[‘reinit_lightboxplus’])) {
    + if (FALSE == $lightboxPlusOptionsExist || isset($_POST[‘reinit_lightboxplus’])) {
    $lightboxPlusPrimaryOptions = $this->lightboxPlusPrimaryInit();
    $lightboxPlusSecondaryOptions = $this->lightboxPlusSecondaryInit();
    $lightboxPlusInlineOptions = $this->lightboxPlusInlineInit();
    <<<

Viewing 1 replies (of 1 total)