fix #814: jquery-1.10.1 remove, jquery-1.10.2 add

This commit is contained in:
Joel Kuzmarski
2013-07-23 23:10:10 -05:00
parent 2f03e92a9e
commit 81447be8db
4 changed files with 10 additions and 9 deletions

View File

@@ -1,4 +1,5 @@
### HEAD
* Update to jQuery 1.10.2
* Change media directory from `/assets/` to `/media/`
* Update to Bootstrap 2.3.2
* Update to Google Universal Analytics

File diff suppressed because one or more lines are too long

6
assets/js/vendor/jquery-1.10.2.min.js vendored Normal file

File diff suppressed because one or more lines are too long

View File

@@ -8,7 +8,7 @@
* 3. /theme/assets/css/app.css
*
* Enqueue scripts in the following order:
* 1. jquery-1.10.1.min.js via Google CDN
* 1. jquery-1.10.2.min.js via Google CDN
* 2. /theme/assets/js/vendor/modernizr-2.6.2.min.js
* 3. /theme/assets/js/plugins.js (in footer)
* 4. /theme/assets/js/main.js (in footer)
@@ -23,7 +23,7 @@ function roots_scripts() {
// It's kept in the header instead of footer to avoid conflicts with plugins.
if (!is_admin() && current_theme_supports('jquery-cdn')) {
wp_deregister_script('jquery');
wp_register_script('jquery', '//ajax.googleapis.com/ajax/libs/jquery/1.10.1/jquery.min.js', false, null, false);
wp_register_script('jquery', '//ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js', false, null, false);
add_filter('script_loader_src', 'roots_jquery_local_fallback', 10, 2);
}
@@ -46,7 +46,7 @@ function roots_jquery_local_fallback($src, $handle) {
static $add_jquery_fallback = false;
if ($add_jquery_fallback) {
echo '<script>window.jQuery || document.write(\'<script src="' . get_template_directory_uri() . '/assets/js/vendor/jquery-1.10.1.min.js"><\/script>\')</script>' . "\n";
echo '<script>window.jQuery || document.write(\'<script src="' . get_template_directory_uri() . '/assets/js/vendor/jquery-1.10.2.min.js"><\/script>\')</script>' . "\n";
$add_jquery_fallback = false;
}