benzeman
01-01-11, 10:38
Hello!
I had some problems with overflow:hidden in IE6. A quick google found I needed to set width:100% and then all was OK - except the background colours for columns 1 (middle) and 3 (left most) had GONE! I found the problematic code for column 3 - but I can't find any issues with the code for column 1! Its probably really obvious, but I haven't spotted :( (I'm using IE6 from MultipleIE's to check IE6 compatibility). I know that IE6 should really be dead now - but as it isn't I still have to code for its buggyness.
Anyway - here is the code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Page | Title</title>
<style type="text/css">
body { margin: 0px; padding: 0px; font-family: Trebuchet MS, Arial, Helvetica, sans-serif; background-color: #cccccc; }
#centered { margin: 0 auto; min-width: 600px; width: 90%;}
div { margin: 0px; }
h1, h6 { background-color: #996699; color: #000000; padding: 0.25em; margin: 0px; }
h2 { border-bottom: solid 1px #ff0000; margin-top: 0px;}
p { margin: 0px; }
/* here come's the heavy lifting */
.column-wrap { position: relative; overflow: hidden; width: 100% !important; height: 100%;}
.column-1, .column-2, .column-3 {padding-bottom: 32767px !important; margin-bottom: -32767px !important;}
.column-1 { margin-left: 175px; margin-right: 175px; background-color: #ffcc00;}
.column-2 { position: absolute; right: 0px; top: 0px; width: 175px; background-color: #ff9900; }
.column-3 { position: absolute; left: 0px; top: 0px; width: 175px; background-color: #ff6600; }
</style>
</head>
<body>
<div id="centered">
<div class="header"><h1>Header</h1></div>
<div class="column-wrap">
<div class="column-1-wrapper">
<div class="column-1">
<h2>Column One</h2>
<p>Filler</p>
<p>Filler</p>
<p>Filler</p>
<p>Filler</p>
<p>Filler</p>
<p>Filler</p>
<p>Filler</p>
<p>Filler</p>
<p>Filler</p>
</div>
</div>
<div class="column-2-wrapper">
<div class="column-2">
<h2>Column Two</h2>
<p>Filler</p>
<p>Filler</p>
<p>Filler</p>
</div>
</div>
<div class="column-3-wrapper">
<div class="column-3">
<h2>Column Three</h2>
<p>Filler</p>
<p>Filler</p>
<p>Filler</p>
</div>
</div>
</div><!-- close column-wrap -->
<div class="footer"><h6>Footer</h6>
</div>
</div>
</body>
</html>
Thanks very much!!!
I had some problems with overflow:hidden in IE6. A quick google found I needed to set width:100% and then all was OK - except the background colours for columns 1 (middle) and 3 (left most) had GONE! I found the problematic code for column 3 - but I can't find any issues with the code for column 1! Its probably really obvious, but I haven't spotted :( (I'm using IE6 from MultipleIE's to check IE6 compatibility). I know that IE6 should really be dead now - but as it isn't I still have to code for its buggyness.
Anyway - here is the code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Page | Title</title>
<style type="text/css">
body { margin: 0px; padding: 0px; font-family: Trebuchet MS, Arial, Helvetica, sans-serif; background-color: #cccccc; }
#centered { margin: 0 auto; min-width: 600px; width: 90%;}
div { margin: 0px; }
h1, h6 { background-color: #996699; color: #000000; padding: 0.25em; margin: 0px; }
h2 { border-bottom: solid 1px #ff0000; margin-top: 0px;}
p { margin: 0px; }
/* here come's the heavy lifting */
.column-wrap { position: relative; overflow: hidden; width: 100% !important; height: 100%;}
.column-1, .column-2, .column-3 {padding-bottom: 32767px !important; margin-bottom: -32767px !important;}
.column-1 { margin-left: 175px; margin-right: 175px; background-color: #ffcc00;}
.column-2 { position: absolute; right: 0px; top: 0px; width: 175px; background-color: #ff9900; }
.column-3 { position: absolute; left: 0px; top: 0px; width: 175px; background-color: #ff6600; }
</style>
</head>
<body>
<div id="centered">
<div class="header"><h1>Header</h1></div>
<div class="column-wrap">
<div class="column-1-wrapper">
<div class="column-1">
<h2>Column One</h2>
<p>Filler</p>
<p>Filler</p>
<p>Filler</p>
<p>Filler</p>
<p>Filler</p>
<p>Filler</p>
<p>Filler</p>
<p>Filler</p>
<p>Filler</p>
</div>
</div>
<div class="column-2-wrapper">
<div class="column-2">
<h2>Column Two</h2>
<p>Filler</p>
<p>Filler</p>
<p>Filler</p>
</div>
</div>
<div class="column-3-wrapper">
<div class="column-3">
<h2>Column Three</h2>
<p>Filler</p>
<p>Filler</p>
<p>Filler</p>
</div>
</div>
</div><!-- close column-wrap -->
<div class="footer"><h6>Footer</h6>
</div>
</div>
</body>
</html>
Thanks very much!!!