Load jQuery in footer
<?php
/**
* Prints jQuery in footer on front-end.
*/
function ds_print_jquery_in_footer( &$scripts) {
if ( ! is_admin() )
$scripts->add_data( 'jquery', 'group', 1 );
}
add_action( 'wp_default_scripts', 'ds_print_jquery_in_footer' );
?>
Instructions:
By default WordPress has registered the jQuery library to load in the header.
This snippet changes this behaviour.