• Resolved Rok

    (@rok)


    These days most of the plugins are using prototype & Script.aculo.us js. Prototype is now bundled with WordPress version 2.1 onwards. In this case, if you’re using six plugins that use either of these js, then the js is loaded six times.

    Just want to know, is there any plugin that can look for the specified javascripts, and if found loaded can avoid further loading by other plugins?

Viewing 3 replies - 1 through 3 (of 3 total)
  • Moderator Samuel Wood (Otto)

    (@otto42)

    www.ads-software.com Admin

    In this case, if you’re using six plugins that use either of these js, then the js is loaded six times.

    Then you need to update those plugins to not load protoype.js and such, but to use the wp_enqueue_script() functions instead.

    With the addition of these javascripts into WordPress comes a javascript handling system. A plugin (or anything else) can add specific scripts to the system, define dependencies and such, and have them loaded into the page. The code doing this will load scripts in the correct order and it will also avoid duplicates.

    Any plugin loading javascripts the old way is probably not fully 2.1 compatible and needs to be modified to use the new mechanisms.

    Thread Starter Rok

    (@rok)

    Whoosh! sooooooooo simple….thanks Otto42.

    Thread Starter Rok

    (@rok)

    I’ve made a detailed post on this issuse, if anyone else is facing the same problem, read this post.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘How to avoid repetitive calls?’ is closed to new replies.