Re: handling fallback content for still images

Robert Burns wrote:
> No that's fine. Thanks for trying. I'll get access to IE myself and 
> see if I can come up with anything. Somewhere I read that adding the 
> <param> as I did would get IE working. Maybe it's IE7 only. Or maybe 
> its just plain wrong (I think I got if off of Wikipedia).
>
> Take care,
> Rob

A brief test of…

<object type="image/png" data="object.png">
    <param name="src" value="object.png">
    <p>This is fallback content.</p>
</object>

… showed that it didn’t work; Internet Explorer 7 renders what looks 
like an empty “iframe” element instead. Neither the image nor fallback 
content is shown.

On the other hand…

<object type="audio/x-pn-realaudio-plugin" data="D0005.ra">
    <param name="src" value="D0005.ra">
    <p>This is fallback content.</p>
</object>

… /does/ work [http://www.jsgp.us/demos/D0005.html]. Maybe that’s where 
the idea for the “param” element came from.

It looks like you can get Internet Explorer to render images via the 
“object” element if you get rid of that “param” element:

<object type="image/png" data="object.png">
    <p>This is fallback content.</p>
</object>

However, the image is rendered as if it were it were in an iframe and 
includes padding/margins; as a result, there are active scrollbars 
surrounding it unless the “object” element’s dimensions are larger than 
that of the image (including the padding/margins and width of the 
vertical scrollbar). Even if the dimensions are large enough, Internet 
Explorer’s ever‐present vertical (inactive) scrollbar remains and cannot 
be suppressed via “overflow: hidden”. The frame surrounding the image 
(but not the image itself) increases and decreases in size when the zoom 
feature is used; this results in either excessive whitespace or 
scrollbars. Fallback content is not displayed; you get what appears to 
be an empty “iframe” element and an error dialog when the image cannot 
be fetched.

Received on Wednesday, 4 July 2007 00:02:53 UTC