[Plugin: Comment Validation] jQuery library load (2 posts)

  1. kirilln
    Posted 6 years ago #

    I'm the author of the TweetBlender plugin that also relies on jQuery. On one of the sites where our plugins are used together there were problems and I found that your plugin loads jQuery version 1.2.6 (current version is 1.3.2).

    I suggest that you unbundle jQuery from your plugin. WordPress comes with the library already available and is on top of keeping it the latest version.

    Here is an example of what your code might look like:

    // add javascript with dependency on jQuery to public pages only
    function load_js() {
    	wp_enqueue_script('jqvalidate', '/' . PLUGINDIR . '/comment-validation/jquery.validate.pack.js', array('jquery'));
            wp_enqueue_script('main', '/' . PLUGINDIR . '/comment-validation/comment-validation.js', array('jquery','jqvalidate'));


  2. joern.zaefferer
    Posted 6 years ago #

    I've released version 0.4, which should fix this issue. It doesn't bundle jQuery anymore and uses wp_enqueue_script.

Topic Closed

This topic has been closed to new replies.

About this Topic