Fix Height Of An Absolute Positioned Div Tag In A List
I positioned a div tag with absolute position in a grids list, so it is wrapped there by others div's. I would like to make a class that make the height of the absolute positioned
Solution 1:
With javascript/jQuery you can get the height of the parent div and of the x subsequent divs (if you iterate through the divs with .col-11 in this case) then you set the height of your div.
Here is a (stupid) example if you'd want to make all .newevent div 3 times the current cell height:
$(document).ready(function () {
$('.newevent').each(function() {
var parentHeight = parseInt($(this).parent().css('height'));
$(this).css('height', 3 * parentHeight + 'px');
});
})
Post a Comment for "Fix Height Of An Absolute Positioned Div Tag In A List"