Forum Moderators: not2easy
This is driving me nuts. I've tried z-index order and all that but it doesn't seem to be related to that. The problem doesn't appear in Mozilla, IE6, IE5.5 etc.
Lately I've been finding so many obscure CSS bugs in IE5/Win that I feel like pulling my hair out!
Can anyone tell me if I'm doing something wrong?
This is my XHTML code below:
<div class="thumbnailbox">
<a href="paintings_001.htm">
<img class="thumbnailboximage" src="images/paintings_001_tm.jpg" width="74" height="100" border="0" alt="paintings - f.n. souza" />
</a>
</div>
and here's my CSS:
.thumbnailbox {
float: left;
margin-right: 4px;
margin-bottom: 4px;
border-width: 1px;
border-style: solid;
border-color: White;
color: White;
background-color: #A9A9A9;
text-align: center;
width: 140px;
height: 140px;
}
div.thumbnailbox a {
margin: 0px;
padding: 0px;
width: 100%;
height: 100%;
text-decoration: none;
display: block;
}
div.thumbnailbox a:hover {
color: White;
background-color: Black;
}
.thumbnailboximage {
margin-top: 20px;
}
I removed the width 100% and height 100% on the anchor style, because this is causing the problem ... I also changed the style of the image ...
Hope it helps ...
<html>
<head>
<title></title>
<style>
.thumbnailbox {
float: left;
margin-right: 4px;
margin-bottom: 4px;
border-width: 1px;
border-style: solid;
border-color: White;
color: White;
background-color: #A9A9A9;
text-align: center;
width: 140px;
height: 140px;
}
div.thumbnailbox a {
margin: 0px;
padding: 0px;
text-decoration: none;
display: block;
}
div.thumbnailbox a:hover {
color: White;
background-color: Black;
}
.thumbnailboximage {
margin-top: 20px;
margin-bottom: 20px;
}
</style>
</head>
<body>
<div class="thumbnailbox">
<a href="paintings_001.htm"><img class="thumbnailboximage" src="images/paintings_001_tm.jpg" width="74" height="100" border="0" alt="paintings - f.n. souza" /></a>
</div>
</body>
</html>
I'll just omit the "width: 100%", "height: 100%" and "display: block" for IE5, that should stop it from chucking a tantrum :) And the other browsers will get the better looking a:hover effect.