Skip to content

Instantly share code, notes, and snippets.

@dotjosh
Created Mar 20, 2013
Embed
What would you like to do?
(function ($) {
$.fn.fillheight = function () {
return this.each(function () {
$(this)
.height("100%")
.parent().wrapInner("<table style='height:100%;width:100%;margin:0;padding:0;border:0;'/>").end()
.siblings().wrapAll("<tr><td style='padding:0;'></td></tr>").end()
.wrap("<tr><td style='height:100%;padding:0;'></td></tr>");
});
};
})(jQuery);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment