deaddale
9/20/2015 - 12:56 AM

Получение максимального значения высоты из набора

Получение максимального значения высоты из набора

 // set height textBlock and his children : beign
	    function getHeight(oneBlock) {
			return Math.max($(oneBlock).height(), $(oneBlock).outerHeight());
		} 

		$(oneTextBlock).each(function(index, el){
			var thisH = getHeight(this);
			if(thisH > maxHeight){maxHeight = thisH;}
		});

		$(oneTextBlock).each(function(){
			$(this).css('height',maxHeight);
		});
	    // set height textBlock and his children : end