How to have div min height
Basically when you specify a height to a div, ie6 will take it as minimum height. But ie7, firefox, chrome and modern browser will treat as height. So here is a simple way to have minimum height to all web browser.
Css Code:
.test{min-height:50px;height:auto!important;height:50px;}
For example, if you want to give 50px height to a div, Use the above code will work fine. That after 50px the height of the div will automatically expands.
Css Code:
.test{min-height:50px;height:auto!important;height:50px;}
For example, if you want to give 50px height to a div, Use the above code will work fine. That after 50px the height of the div will automatically expands.
Labels: CSS, div min height, html
11 Comments:
This does not work for IE6.
I had to override the min-height on IE6 by using _min-height:inherit;
Also, on IE7 even though min-height is meant to be supported I could only get it to work if I defined both height and min-height...
replace height:50px => _height:50px. this will solve your issue
Thanks it helped me out lots
Wow! I was just not looking for the right keyword. But I found this page when I searched for minimum height div. Great help. Thanks guys.
Thank You so much.....
It was really cool.:)
This is very useful code. Thank you for sharing with us :) Web Designing in Mumbai
Good one ........i really like this post.
Website Maintenance and
Website Development in Mumbai
Everything is fine, am happy about your blog. Thanks admin for sharing the unique content, you have done a great job I appreciate your effort and I hope you will get more positive comments from the web users.
SEO Company in Chennai
I’ve read some good stuff here. Definitely worth bookmarking for revisiting. I surprise how much effort you put to create such a great informative website
Cara Mengatasi Telinga Berdengung
great
Hello There,
Really amazing thoughts. very cool blog you have.
I am impress with your website. Good Website.
visit - best Logo Designing Company in Jaipur | Logo Designer in Jaipur
Post a Comment
Subscribe to Post Comments [Atom]
<< Home