HighDots Forums  

<img> display with height and width attributes

HTML Writing HTML for the Web (comp.infosystems.www.authoring.html)


Discuss <img> display with height and width attributes in the HTML forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Jim Moe
 
Posts: n/a

Default <img> display with height and width attributes - 07-29-2005 , 02:33 AM






Hello,
Mozilla (suite and Firefox) ignore the height and width attributes of
<img> when the image itself is unavailable (404); only enough space is
allocated for the alt text.
Is this expected behavior for Standards mode?

--
jmm dash list (at) sohnen-moe (dot) com
(Remove .AXSPAMGN for email)

Reply With Quote
  #2  
Old   
Henri Sivonen
 
Posts: n/a

Default Re: <img> display with height and width attributes - 07-29-2005 , 02:58 AM






In article <1JadnT_Jmt5TUHTfRVn-hQ (AT) giganews (DOT) com>,
Jim Moe <jmm-list.AXSPAMGN (AT) sohnen-moe (DOT) com> wrote:

Quote:
Mozilla (suite and Firefox) ignore the height and width attributes of
img> when the image itself is unavailable (404); only enough space is
allocated for the alt text.
Is this expected behavior for Standards mode?
Yes.

--
Henri Sivonen
hsivonen (AT) iki (DOT) fi
http://hsivonen.iki.fi/
Mozilla Web Author FAQ: http://mozilla.org/docs/web-developer/faq.html


Reply With Quote
  #3  
Old   
Spartanicus
 
Posts: n/a

Default Re: <img> display with height and width attributes - 07-29-2005 , 03:33 AM



Jim Moe <jmm-list.AXSPAMGN (AT) sohnen-moe (DOT) com> wrote:

Quote:
Mozilla (suite and Firefox) ignore the height and width attributes of
img> when the image itself is unavailable (404); only enough space is
allocated for the alt text.
Is this expected behavior for Standards mode?
There's no such thing as "expected behaviour". The behaviour is
undefined as per the specifications, thus Mozilla is neither wrong nor
right.

--
Spartanicus


Reply With Quote
  #4  
Old   
Chris Beall
 
Posts: n/a

Default Re: <img> display with height and width attributes - 07-29-2005 , 01:11 PM



Jim Moe wrote:

Quote:
Hello,
Mozilla (suite and Firefox) ignore the height and width attributes of
img> when the image itself is unavailable (404); only enough space is
allocated for the alt text.
Is this expected behavior for Standards mode?

Jim,

Ambiguous.

The spec says (section 13.2), "The alt attribute specifies alternate
text that is rendered when the image cannot be displayed (see below for
information on how to specify alternate text ). User agents must render
alternate text when they cannot support images, they cannot support a
certain image type or when they are configured not to display images."
:
"Please consult the section on the visual presentation of objects,
images, and applets for information about image size, alignment, and
borders."

And that section (13.7) says, "When specified, the width and height
attributes tell user agents to override the natural image or object size
in favor of these values."

So it's a question of whether rendering alternate text supersedes or
replaces the overriding of natural image size (which is unknown in the
case you describe) by the height and width parameters.

If all of the ambiguities in the HTML specs were laid end to end....

Chris Beall, who prefers the Mozilla interpretation.





Reply With Quote
  #5  
Old   
Jim Moe
 
Posts: n/a

Default Re: <img> display with height and width attributes - 07-29-2005 , 06:43 PM



Jim Moe wrote:
Quote:
Hello,
Mozilla (suite and Firefox) ignore the height and width attributes of
img> when the image itself is unavailable (404); only enough space is
allocated for the alt text.
Is this expected behavior for Standards mode?

Thanks for your responses. Yes, the spec was curiously silent on this
aspect.

--
jmm dash list (at) sohnen-moe (dot) com
(Remove .AXSPAMGN for email)


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.