W3C home > Mailing lists > Public > www-dom@w3.org > January to March 2003

width/height attributes on HTMLImageElement and HTMLObjectElement

From: Boris Zbarsky <bzbarsky@MIT.EDU>
Date: Mon, 31 Mar 2003 18:46:25 -0500
Message-Id: <200303312346.SAA05001@nerd-xing.mit.edu>
To: www-dom@w3.org

I was just looking at the "width" and "height" attributes of HTMLImageElement
and HTMLObjectElement.  These are desribed somewhat differently... The Image
version says (for height): "Height of the image in pixels. See the height
attribute definition in HTML 4.01."  The Object version says: "Override
height. See the height attribute definition in HTML 4.01."

Are these expected to act in similar ways?  HTMLImageElement.height will be the
"intrinsic" image height in current browsers if the "height" attribute is not
set in the HTML.  This behavior is needed because legacy content relies on
it... but is that just a browser quirk or part of the DOM2 HTML specification?

Boris
-- 
Economists state their GNP growth projections to the
nearest tenth of a percentage point to prove they have a
sense of humor.
                             -- Edgar R. Fiedler
Received on Monday, 31 March 2003 18:46:27 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Friday, 22 June 2012 06:13:56 GMT