So apparently I am now allowed to do the following in the admin, ON my theme options page and only ON my theme options pages:
public function load_admin_jquery(){
if(isset($this->_options['admin_jquery_version'])){
wp_deregister_script ( 'jquery' );
wp_register_script ( 'jquery', 'http://ajax.googleapis.com/ajax/libs/jquery/'.$this->_options['admin_jquery_version'].'/jquery.min.js' );
wp_enqueue_script ( 'jquery', true, true );
}
}
Can some one explain why? I am only setting the new version of jquery ON my theme options pages ONLY
The exact error is:
Notice: wp_deregister_script was called incorrectly. Do not deregister the
jquery
script in the administration area. To target the frontend theme, use thewp_enqueue_scripts
hook. Please see Debugging in WordPress for more information. (This message was added in version 3.6.) in /var/www/wordpress/wp-includes/functions.php on line 2986
I have Twitter bootstrap loading in my theme options page and I would like to be in control of the jquery version being used.