I make my elements in the same height, everything works good (it works on page load), but it does not work on resize. Need your help
function same_height() {
$('.front-section').children(".row").each(function() {
var maxHeight= -1;
$(this).find(".owl-item").each(function() {
maxHeight = maxHeight > $(this).height() ? maxHeight :
$(this).height();
});
$(this).find(".owl-item").each(function() {
$(this).height(maxHeight);
})
});
}
$(window).on('load',same_height);
$(window).on('resize',same_height);