Last active
August 29, 2015 14:27
-
-
Save neilgee/dbbeb9870f2617034180 to your computer and use it in GitHub Desktop.
Equal Heights in Columns Using jQuery
This file contains 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
<?php | |
function wpb_match_height() { | |
wp_enqueue_script ( 'matchheight' , get_stylesheet_directory_uri() . '/js/jquery.matchHeight-min.js', array( 'jquery' ), '1', true ); | |
wp_enqueue_script ( 'matchheight-init' , get_stylesheet_directory_uri() . '/js/matchheight-init.js', array( 'matchheight' ), '1', true ); | |
} | |
add_action( 'wp_enqueue_scripts', 'wpb_match_height' ); |
This file contains 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
jQuery(function($) { | |
$('.post').matchHeight(); //set your target CSS class | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment