html head style .100PercentHeight{ } /style /style body div class='100PercentHeight'hihi/div /body/html 如何将div拉伸到页面的100%高度? 尝试(它应该适用于大多数浏览器): .100PercentHeight, html, body { height : a
<html>
<head>
<style>
.100PercentHeight{ }
</style>
</style>
<body>
<div class='100PercentHeight'>hihi</div>
</body>
</html>
如何将div拉伸到页面的100%高度?
尝试(它应该适用于大多数浏览器):.100PercentHeight, html, body {
height : auto !important; /* Ignored by Internet Explorer, applied everywhere else. */
height : 100%; /* Internet Explorer treats as min-height. */
min-height : 100%; /* Internet Explorer ignores this. */
}
