Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

"Width": IE vs Firefox

Status
Not open for further replies.

wetodit

MIS
May 9, 2002
7
0
0
US
Hi everyone,
I have a technical question regarding a css attribute.
How come that when using something simple like this:

#BLAH {
width: 200px;
}

IE will stretch the width if an item is bigger, but Firefox keeps the width at 200? Do I need to specify an absolute position for it to not stretch in either case?
Thanks!
wetodit
 
You have to curse Microsoft for not following standards. If you specify [tt]width: 200px;[/tt], the element should stay 200px regardless of the contents. M$ messed up their browser and this property in IE behaves just like [tt]min-width: 200px;[/tt] in standards-compliant browsers. What type of content is stretching your element and why can't you do something to avoid it?
 
I had a similar problem a while back and ended up using an IFRAME inside a 200px wide table cell. Think this worked in FF and IE!
 

Try adding "overflow: hidden;".

Hope this helps,
Dan


[tt]D'ya think I got where I am today because I dress like Peter Pan here?[/tt]
[banghead]

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top