Support » Theme: Newsphere » assets/script.js contains deprecated JQuery function calls

  • Javascript files “/wp-content/themes/newsphere/assets/script.js“,
    /assets/marquee/jquery.marquee.js“, and
    /assets/pagination-script.js
    contain code that has been deprecated in the new JQuery version in the update to WP5.6. The problem presented itself (in my case) as the ‘White Screen of Death’ (WSoD) after upgrading to WP 5.6, which could be temporarily ‘fixed’ by clearing browser cache.

    The jQuery Migrate Helper plugin shows the following among other errors:

    jQuery.fn.hover() event shorthand is deprecated
    jQuery.fn.click() event shorthand is deprecated
    jQuery.fn.scroll() event shorthand is deprecated
    jQuery.fn.load() event shorthand is deprecated
    …etc.

    Easy fix is to change:
    .click(func) to .on(‘click’, func)
    .load(func) to .on(‘load’, func)
    …etc.

    MLG4035

Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
  • The topic ‘assets/script.js contains deprecated JQuery function calls’ is closed to new replies.