Log in

View Full Version : Resolved Relative width in IE



Rando
06-15-2009, 05:01 PM
Hello All,

I've searched at quite a few places but I couldn't find the answer yet, and I hope you can help me! I'm currently coding the new site for the Dutch World of Warcraft Fansite and I'm trying to get the banner in the center 100% of the TD width. Firefox handles this great, but IE totally ignores the class and uses the original width, while it dóes use the new height!

CSS class:

.picture {
width: 100%;
height: 200px;
}

HTML:

<img id="r1" src="img/nieuws/laden.png" alt="" border="0" width="100%" class="picture">

I did find a few things regarding IE being different, but is there a way to work around this?

Rando

X96 Web Design
06-18-2009, 09:12 PM
Have you tried removing the width="" attribute in the <IMG>? Because you haven't put a height attribute, and that may be why the height works.

Hope this helps,
X96

Rando
06-20-2009, 05:06 PM
Thanks for the answer!

Sadly, even after removing the width="" tag, Internet Explorer still ignores the tag!

Anymore suggestions? :)

bluewalrus
06-20-2009, 06:20 PM
Have you tried margin:auto; on the cell?

or is there more stuff in the cell you don't want centered?

Rando
06-22-2009, 01:27 PM
That did the trick, many thanks!

This is the result;
http://www.wow-nl.com/beta

The matter was about the rotating pictures in the middle :)

Thanks,

Rando