Log in

View Full Version : *slightly* stupid CSS question for IE6



FrickenTrevor
01-18-2010, 06:35 AM
Anyone know how to take this code here


<style>
img.i1 {
margin: 0 auto;
display: block;
border: 0;
}
</style>

<img class="i1" src="media/images/notepad.png" width="55px" height="55px" alt="">

and make it work for IE 6?

The code works for IE 7. But when I view my site in IE6, the images become weird.

This is not a homework asignment and my site cannot be viewed. Thanks

tpravioti
01-18-2010, 02:36 PM
try this:



<style>
img.i1 {
margin: 0 auto;
display: block;
border: none;
}
</style>

<img class="i1" src="media/images/notepad.png" width="55" height="55" alt="">

bluewalrus
01-18-2010, 02:42 PM
http://24ways.org/2007/supersleight-transparent-png-in-ie6

or you could also try


<img class="i1" src="media/images/notepad.png" style="width:55px; height:55px;" alt="">

but I think it is a problem with the image formatting and ie6.