Skip to content

Instantly share code, notes, and snippets.

@bclennox
Created September 28, 2009 12:27
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bclennox/195393 to your computer and use it in GitHub Desktop.
Save bclennox/195393 to your computer and use it in GitHub Desktop.
// set the parent container's height to the height of its tallest child
var $container = $("...");
var max_height = 0;
$container.children("section").each(function (){
max_height = Math.max(max_height, $(this).height());
});
$container.height(max_height);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment