Title: [Plugin: Wp Ajax Tree] Bad jQuery Loading
Last modified: August 20, 2016

---

# [Plugin: Wp Ajax Tree] Bad jQuery Loading

 *  [Barry Carlyon](https://wordpress.org/support/users/barrycarlyon/)
 * (@barrycarlyon)
 * [14 years, 9 months ago](https://wordpress.org/support/topic/plugin-wp-ajax-tree-bad-jquery-loading/)
 *     ```
       if(wp_script_is('jquery','registered')) {
           $ver = $wp_scripts->registered['jquery']->ver;
           wp_deregister_script('jquery');
           wp_register_script('jquery', ("http://ajax.googleapis.com/ajax/libs/jquery/$ver/jquery.min.js"), false, $ver);
           if(!is_admin()) wp_enqueue_script('jquery');
         }
       ```
   
 * should be
 *     ```
       if(wp_script_is('jquery','registered') && !is_admin()) {
           $ver = $wp_scripts->registered['jquery']->ver;
           wp_deregister_script('jquery');
           wp_register_script('jquery', ("http://ajax.googleapis.com/ajax/libs/jquery/$ver/jquery.min.js"), false, $ver);
           wp_enqueue_script('jquery');
         }
       ```
   
 * [http://wordpress.org/extend/plugins/wp-ajax-tree/](http://wordpress.org/extend/plugins/wp-ajax-tree/)

The topic ‘[Plugin: Wp Ajax Tree] Bad jQuery Loading’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/wp-ajax-tree.svg)
 * [Wp Ajax Tree](https://wordpress.org/plugins/wp-ajax-tree/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wp-ajax-tree/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wp-ajax-tree/)
 * [Active Topics](https://wordpress.org/support/plugin/wp-ajax-tree/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wp-ajax-tree/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wp-ajax-tree/reviews/)

 * 0 replies
 * 1 participant
 * Last reply from: [Barry Carlyon](https://wordpress.org/support/users/barrycarlyon/)
 * Last activity: [14 years, 9 months ago](https://wordpress.org/support/topic/plugin-wp-ajax-tree-bad-jquery-loading/)
 * Status: not resolved