diff --git a/wp-content/themes/twentythirteen/functions.php b/wp-content/themes/twentythirteen/functions.php index e05098ba71..c641b38f40 100644 --- a/wp-content/themes/twentythirteen/functions.php +++ b/wp-content/themes/twentythirteen/functions.php @@ -224,7 +224,7 @@ function twentythirteen_scripts_styles() { wp_enqueue_script( 'jquery-masonry' ); // Loads JavaScript file with functionality specific to Twenty Thirteen. - wp_enqueue_script( 'twentythirteen-script', get_template_directory_uri() . '/js/functions.js', array( 'jquery' ), '20130416', true ); + wp_enqueue_script( 'twentythirteen-script', get_template_directory_uri() . '/js/functions.js', array( 'jquery' ), '20130423', true ); // Loads our main stylesheet. wp_enqueue_style( 'twentythirteen-style', get_stylesheet_uri() ); diff --git a/wp-content/themes/twentythirteen/js/functions.js b/wp-content/themes/twentythirteen/js/functions.js index 0c9a8d1c10..e96877c184 100644 --- a/wp-content/themes/twentythirteen/js/functions.js +++ b/wp-content/themes/twentythirteen/js/functions.js @@ -52,7 +52,7 @@ if ( _window.innerWidth() > 644 ) { _window.on( 'scroll.twentythirteen', function() { var scrollOffset = scrollOffsetMethod ? document.documentElement.scrollTop : window.scrollY; - + if ( scrollOffset > navbarOffset ) html.addClass( 'navbar-fixed' ); else @@ -100,11 +100,11 @@ * @link http://www.nczonline.net/blog/2013/01/15/fixing-skip-to-content-links/ */ _window.on( 'hashchange.twentythirteen', function() { - var element = $( location.hash ); + var element = document.getElementById( location.hash.substring( 1 ) ); if ( element ) { - if ( ! /^(?:a|select|input|button)$/i.test( element.tagName ) ) - element.attr( 'tabindex', -1 ); + if ( ! /^(?:a|select|input|button|textarea)$/i.test( element.tagName ) ) + element.tabIndex = -1; element.focus(); }