• Resolved joelmellin

    (@joelmellin)


    Hi,

    In Google Console I get an jQuery error that is caused by the Product Filter. The problem should be in the base plugin.
    This is the offending code. The first jQuery is not defined.

    public function addScriptsLisener() {
    $js = ‘var v = jQuery.fn.jquery;
    if (v && parseInt(v) >= 3 && window.self === window.top) {
    var readyList=[];
    window.originalReadyMethod = jQuery.fn.ready;
    jQuery.fn.ready = function(){
    if(arguments.length && arguments.length > 0 && typeof arguments[0] === “function”) {
    readyList.push({“c”: this, “a”: arguments});
    }
    return window.originalReadyMethod.apply( this, arguments );
    };
    window.wpfReadyList = readyList;
    }’;
    wp_add_inline_script(‘jquery’, $js, ‘after’);
    }

    The page I need help with: [log in to see the link]

Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Jquery issue’ is closed to new replies.