IE6 supports compatible max-height, min-height CSS Styles

Source: Internet
Author: User

1, IE6 support Max-height solution-TOP

IE6 supports maximum height resolution of CSS code:
. Yangshi{max-height:1000px;_height:expression ((document.documentelement.clientheight| | document.body.clientHeight) <1000? " 1000px ":"); Overflow:hidden;}

Description: max-height:1000px; This is IE6. The maximum range height is supported by other brand browsers. and _height:expression ((document.documentelement.clientheight| | document.body.clientHeight) <1000? " 1000px ":"); overflow:hidden; let IE6 support max-height instead of CSS code, but the effect is the same as other versions of the browser.

Let all browsers support Max-height CSS style code, complete:
Max-height:1000px;_height:expression ((document.documentelement.clientheight| | document.body.clientHeight) <1000? " 1000px ":"); Overflow:hidden: The 1000 and 1000px here are the values you need, note that the 3 values are the same.

Let IE6 support maximum height max-height don't forget to add overflow:hidden;

2, IE6 support Min-height solution-TOP

IE6 supports minimum height resolution of CSS code:
. Yangshi{min-height:1000px;_height:expression ((document.documentelement.clientheight| | document.body.clientHeight) >1000? " 1000px ":" ");}

Description: min-height:1000px; This is IE6. Other brand browsers support a minimum range of heights. and _height:expression ((document.documentelement.clientheight| | document.body.clientHeight) >1000? " 1000px ":"); let IE6 support CSS min-height instead of CSS code, but the effect is the same as other versions of the browser.

Let all browsers support Min-height CSS style code, complete:
Min-height:1000px;_height:expression ((document.documentelement.clientheight| | document.body.clientHeight) >1000? " 1000px ":"); The 1000 and 1000px here are the values you need, note that the 3 values are the same.

3, IE6 support Max-height and support Min-height Method-TOP

Allow all browsers including IE6 to support the maximum height and support the minimum height.
. yangshi{max-height:620px; Min-height:40px;_height:expression (This.scrollheight > 620?) "620px": (This.scrollheight < 40?) "40px": "Auto");}

IE6 supports max-height and supports min-height CSS code
_height:expression (This.scrollheight > 620?) "620px": (This.scrollheight < 40?) "40px": "Auto"));

Description: The above code function is to make the object's minimum height of 40px, the maximum height of 620px CSS style properties

IE6 supports compatible max-height, min-height CSS Styles

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.