• Hello,

    We are using the plugin with multiple widgets to filter on several different types of attributes, some of which don’t show in certain searches/categories. There seems to be a bug when a widget is not used for a particular search, style="display:none;" > displays to the user because it is inserted after the closing > of the widget div.

    I think I’ve located the source of the problem:

    if ( ! $found )  {
                        ob_end_clean();
                        echo substr($before_widget, 0, strlen($before_widget) - 1) . ' style="display:none">' . $after_widget;
                    } else {
                        echo ob_get_clean();
                    }

    Editing yith-woocommerce-ajax-navigation/widgets/class.yith-wcan-navigation-widget.php line 656 to read

    echo substr($before_widget, 0, strlen($before_widget) - 2) . ' style="display:none">' . $after_widget;

    seems to sort the problem – can this be fixed in the next release of the plugin please?

    Thanks!

    https://www.ads-software.com/plugins/yith-woocommerce-ajax-navigation/

Viewing 3 replies - 1 through 3 (of 3 total)
  • organu

    (@organu)

    For me style=”display:none;” only appears when on before and after widget i have no div, li etc declared

    creativemind1

    (@creativemind1)

    Same here. It is not working for me as well. This is what it shows me (html format)

    <li id="yith-woo-ajax-reset-navigation-2" class="widget yith-woo-ajax-reset-navigation yith-woo-ajax-navigation woocommerce widget_layered_nav" style="display:none">

    In the version 1.3.2 of the plugin it’s line 736

    ‘echo substr( $before_widget, 0, strlen( $before_widget ) – 1 ) . ‘ style=”display:none”>’ . $after_widget;’

    I changed -1 to -2 and that worked!

    Unfortunately this doesn’t seem to work this the ‘reset’ filter. Here I still see the style=”display:none;” > in my website.

    Any suggestions?

    Edit: If you have selected something, there is no problem, but after resetting all to default, text “style=”display:none;” >” is visible.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘'style="display: none;" >' Displaying in sidebar’ is closed to new replies.