Public Voice Network
- Beeeees! 88
- New York 77
- the gif animation thread 1283412834
- What is THEIR work? 55
- Battlefield 3 304304
- Random Fascinations? 33
- Music over 5.1 System 33
- FACE EATER 1010
- Meme of the day 1414
- Letterpress process video 33
- News of the day... 137137
- Video Cameras Under $2000 77
- ATTN: Greedy Republicans 2323
- Pic of the Day 6330063300
- Chick of the Day 1537915379
- Show your latest Pics 32943294
- XBMC 33
- what happened? 2222
- F1 2012 1919
- Vid of the Day 1203312033
- paper trail 88
- Facebook IPO 156156
- Diablo III 8383
- Coda 2 3434
css problem 77 Responses
Last post: 2 years, 2 months ago | Thread started: Mar 9, 10, 5:10 a.m.
- flashbender
most typically this can occur when a float is not cleared.
Put a <br style="clear:both" /> and see if that fixes it.
one big issue is that you have the same ID for all of your projects:
div id="projects1"you can easily fix this by making that a class instead of an ID selector.
Also, instead of padding-top, padding-bottom... you can just use:
padding:10px 25px 10px 25px.
the order of that is top right bottom left. this is true of border as well.
I would also recommend rewriting using actual HTML tags instead of custom classes e.g. use an H1 tag instead of "textheader". This not only makes your pages more accessible, but it also makes them more SEO friendly. For more info on this look up semantic markup.
a couple links that deal with IE quirks and CSS positioning:
http://www.positioniseverything.…
http://www.barelyfitz.com/screen…regarding design for old browsers - it depends on your target audience and how much time and effort you wish to spend developing the site... but you can't ignore that IE 6&7 together still account for more than 20% of browsers according to W3C.
also, your code looks overly complicated for what you are trying to do.


- Dog-earMar 9, 10, 5:36 a.m. – Permalink
- flashbender
in the simpliest layout, all you need is:
<style type="text/css">
<!--body{
padding:0;
margin:0;
text-align:center;
}
.contentBox{
width:622px;
text-align:left;
margin:0 auto;
}.header {
font-size: 14px;
padding:10px;
margin:0 0 10px 0;
background-color:#CCC;
border:1px dotted #CCC;
width:600px;
}.item {
font-size: 10px;
padding:10px;
margin:0 0 10px 0;
background-color:#F1F1F1;
border:1px dotted #333;
width:600px;
}
-->
</style>
</head><body>
<div class="contentBox">
<div class="header style1">Header</div>
<div class="item">item</div>
<div class="item">item</div>
<div class="item">item</div>
</div>
</body>

- Dog-earMar 9, 10, 5:42 a.m. – Permalink
- welded
Fixed positioning doesn't work in earlier versions of IE. You can either forget about it and add some top margins to your body so the content doesn't end up underneath the header and the page will otherwise work as normal or go for more messy solution... Search for something like 'position fixed ie' and you'll get pages like this one: http://www.howtocreate.co.uk/fix…


- Dog-earMar 9, 10, 5:42 a.m. – Permalink



