Support » Plugins and Hacks » [Plugin: Comment Validation] jQuery library load

  • Hello,
    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
    add_action("template_redirect","load_js");
    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'));
    }

    http://wordpress.org/extend/plugins/comment-validation/

Viewing 1 replies (of 1 total)
  • I’ve released version 0.4, which should fix this issue. It doesn’t bundle jQuery anymore and uses wp_enqueue_script.

Viewing 1 replies (of 1 total)
  • The topic ‘[Plugin: Comment Validation] jQuery library load’ is closed to new replies.