Created
October 5, 2015 17:13
-
-
Save ajithrn/97fb51e8696baf177519 to your computer and use it in GitHub Desktop.
WordPress: Inclide Jquery
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Add jQuery from google cdn | |
*/ | |
function add_jquery_script() { | |
wp_deregister_script( 'jquery' ); | |
wp_register_script( 'jquery', 'https://ajax.googleapis.com/ajax/libs/jquery/1.11.2/jquery.min.js', '', false); | |
wp_enqueue_script( 'jquery' ); | |
} | |
add_action('wp_enqueue_scripts', 'add_jquery_script'); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment