Help Me, CSS Gurus
- Posted by Johanna on December 12, 2005 at 7:30 pm
- Category: Meta
I just found out today that images on my review posts are not displaying properly on Windows machines using Internet Explorer. The images are displaying below the boxes they’re supposed to be inside. This is, from what I can gather, due to a known bug in the way IE implements CSS. However, I can’t figure out how to fix it, because I have no effective way to text my fixes. (I use a Mac.)
Is there some site out there that mimics the behavior of IE 6 on Windows, or some way I can fake it on my machine? Alternately, is there a CSS guru who can tell me what needs to be done to the following style definition to make the site work? It looks fine everywhere else (IE Mac, Safari, Firefox both Mac and Windows).
.right {
float: right;
margin: 0px 5px 0px 10px;
font-family: Verdana, Arial, Georgia, sans-serif;
}
Update: I added “display: inline” to the right class above — can someone using IE on Windows tell me if that worked?
Update 2: Fixed with David’s “position: relative”. Thanks!
December 12, 2005 at 8:45 PM
I had this exact same problem with images inside tables.. I didn’t realise this was happening to IE.
To solve it, add another line above float:right; to say
position: relative;
So the code should show
.right {
position: relative;
float: right;
margin: 0px 5px 0px 10px;
font-family: Verdana, Arial, Georgia, sans-serif;
}
That should help the IE problem
December 12, 2005 at 9:52 PM
Ironical, isn’t it? IE is rapidly becoming a minority among certain communities, it seems.
I don’t use it, on either Mac or Windows, unless required to by circumstance or employment. Kinda like using a screwdriver to pound in nails – works, but not well.
December 12, 2005 at 10:49 PM
can someone using IE on Windows tell me if that worked?
It didn’t. I have IE 6 on Win XP, and the pictures do not align correctly.
December 13, 2005 at 9:46 AM
I think IE is getting hung up on calling two classes on one div. You may try splitting them up like this:
See if that helps! Not as elegant, but if I had to take a quick guess, that would be it.
December 13, 2005 at 9:49 AM
Hrm… WP stripped out all of my code :)
Shoot me an email if you can’t retrieve the code from the comment table in the database!
December 13, 2005 at 10:04 AM
David, you rock! That did it! Thank you so much.
Danny, I don’t know why anyone would choose to use IE when tabbed browsing and ad-blocking plug-ins are available for Firefox, but it’s still out there in lots of places.
Max, thanks for the assistance!
December 13, 2005 at 1:08 PM
I’m glad it work! ^.^