> -----Original Message----- > From: Thierry Koblentz [mailto:[EMAIL PROTECTED] > Sent: Sunday, October 19, 2008 6:00 PM > To: 'Alex Cole'; '[email protected]' > Subject: RE: [css-d] IE absolute and relative height problem > > > -----Original Message----- > > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] > > discuss.org] On Behalf Of Alex Cole > > Sent: Sunday, October 19, 2008 5:35 PM > > To: [email protected] > > Subject: [css-d] IE absolute and relative height problem > > > > Hi. > > > > This seems to be the opposite to what almost everyone else everywhere wants > to > > know, I've searched all over before coming here and couldn't find anything > on > > it. I don't know if I was just looking in the wrong place or didn't know > how > > to correctly and concisely describe the problem in a search engine but > anyway, > > any pointers on the matter would be helpful. > > > > I have a div set as 200px x 200px with another div inside it with height > 100% > > and width 100%. The inner div has overflow:hidden and content far longer > than > > the specified 200px height. In FF, Opera, Chrome and Safari this displays > > exactly as I would expect with the inner content getting cut off at the > 200px > > line, however in IE, no matter what I try, it seems to stretch the parent > div > > to as big as the contents. There is a very basic demo of the problem here: > > http://www.y-less.com/yavascript/ietest.html > > > > If anyone knows about the solution to this problem your help would be much > > appreciated, I find it hard to believe from the number of results that this > is > > an uncommon problem. > > > Replace this: > <!doctype HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> > > With this: > <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" > "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
Sorry, the above is a XHTML DTD, use this one instead: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> -- Regards, Thierry | http://www.TJKDesign.com ______________________________________________________________________ css-discuss [EMAIL PROTECTED] http://www.css-discuss.org/mailman/listinfo/css-d List wiki/FAQ -- http://css-discuss.incutio.com/ List policies -- http://css-discuss.org/policies.html Supported by evolt.org -- http://www.evolt.org/help_support_evolt/
