I have make a script for make columns the same height. This is my script:
function equalHeight(group) {
tallest = 0;
group.each(function() {
thisHeight = $(this).outerHeight();
if(thisHeight > tallest) {
tallest = thisHeight;
}
});
group.outerHeight(tallest);
};
equalHeight($(".list-links li"));
But i have a problem. In my website, i use jquery ui core. But i want delete that jquery ui. But if I remove the jquery ui. Then this script does not work anymore. Why?
Thanks for helping.
jQuery’s
.outerHeightdoesn’t work as a setter method as you can see from the documentation. So, this line of codedoesn’t have any effect without jQuery UI.
jQuery UI wraps
.inner*and.outer*methods and extend them with a setter method as you can see in the excerpt below from jquery.ui.core.js.These setters, for instance
.outerHeight, sets the height of the element without the padding, border and optionally the margin.