Support » Plugin: Akismet » $.live method deprecated in latest jquery

  • Akismet still uses the deprecated jquery method $.live. WordPress core and jetpack have already updated their methods to the new jquery methods after I encouraged them to do so; I would now encourage akismet to do the same. In wp-content/plugins/akismet/akismet.js the $.live method is called twice, once on line 32 and once on line 59.
    You should now use a method like “$.on”. So line 59 would become:

    jQuery('document').on('click','.akismet_undo_link_removal', function () {

    And line 32 would become:

    jQuery('document').on('click', '.remove_url', function () {

Viewing 1 replies (of 1 total)
  • YES, I got the following message in WordPress admin panel due to this bug.

    “Uncaught TypeError: Object [object Object] has no method ‘live’ akismet.js?ver=2.5.9:32”

    Although jquery-migrate.min.js is loaded, it doesn’t fix because other plugin called admin_enqueue_scripts().

    Akismet could you please update the $.live() method as cappellania.uniroma3 suggested?

Viewing 1 replies (of 1 total)
  • The topic ‘$.live method deprecated in latest jquery’ is closed to new replies.