- From: Philip Taylor <pjt47@cam.ac.uk>
- Date: Sat, 03 May 2008 20:50:26 +0100
- To: Robert J Burns <rob@robburns.com>
- CC: Henri Sivonen <hsivonen@iki.fi>, "public-html@w3.org" <public-html@w3.org>
Robert J Burns wrote: > On May 3, 2008, at 1:56 PM, Smylers wrote: > >> 1 This webpage conforms to the HTML 5 standard except that it includes >> unknown images from external sources for which we are unable to >> provide alterternative text. > > This conveys another myth we need to dispel immediately. Few should ever > be authoring a page where they do not know why they included an image on > the page (perhaps this is part of the same misconception I'm already > trying to dispel). All anyone has to do is remove the image from the > page, decide whether the page is missing something important in not > having that image there. If it is, put the image back and briefly > describe what was missing without the image. Perhaps you or someone > could point us to a real world example of a page where you think the > purpose of the image on the page is inexplicable. That way we could > continue the dialog and demonstrate that it's not the case. http://validator.nu/?doc=http%3A%2F%2Fnews.bbc.co.uk%2F&showimagereport=yes&showsource=yes#imagereport Those unknown images from external sources on Validator.nu are a critical part of the content, and there is usually no available equivalent textual alternative for them. (The purpose of these images isn't "inexplicable", but they seem to match what Smylers was describing, and Henri appears to think alt should be omitted for them.) My attempt at understanding this specific case: The site knows: * The existence of the image on the page. * The image's filename. * That the image is critical to the functionality of the page. The UA knows: * The existence of the image. * The image's filename. * The image's bitmap data. The user wants to know: (a) That the image is critical to the functionality of the page. (b) Details about the structure and content of the image. ((a) is important for the user because it means they should spend some effort to examine the image in detail. They wouldn't want to spend the same amount of effort on most other images on the web, because most aren't that critical and it would be a waste of time.) The UA can decide very little about (a) from the alt attribute being absent, present, or set to "", since all those possibilities are abused by existing content. So the site cannot unambiguously convey the importance to the UA, because the UA cannot trust the site to be correct. The UA can discover some of (b) (details about the image's content) from having downloaded the image data, e.g. reporting its filename and dimensions, deciding whether it's iconic (small, few colours, high contrast, sharp edges) or photographic, looking at the metadata inside JPEGs/PNGs, etc. The site knows nothing about (b), since it doesn't have the image data (and it would be too slow and expensive and insecure for it to download all the images itself), so it can't help with that at all. The user can be quite certain about (a) because of context: they know this is in Validator.nu's image report output, so they require only that the UA indicates the existence of the image, and then they will know it is an important image and worth examining in more detail. So, the goal of the site's markup is to make sure the UA tells the user clearly and concisely that there is an image here. It is up to the UA to determine as much detail as possible about the image, and it is up to the user to decide (based on context) that the image is important and that it is worth looking at in detail. In that case, <img src="..." alt="External image"> seems to achieve the goal: as long as UAs do not ignore images with alt text, the user will be made aware that the image exists, and can ask their UA for further details. It is also slightly more informative to users than <img src="..."> (no alt) could be, since it can say that this is an external image (or some other terminology indicating that it's from the reported site, rather than being a part of Validator.nu itself), which is information that is impossible for the UA to deduce. Also, a UA that performs some image analysis to optimise the rendering of typical (non-conforming) web pages should treat <img src="blank.gif"> (where blank.gif is a 1x1-pixel transparent image) as equivalent to <img src="blank.gif" alt=""> (i.e. ignore the image entirely), because the image typically conveys no information. In the Validator.nu case that would be harmful, because the user must still be made aware of the image's existence, and so Validator.nu should not use markup that will cause this type of problem. So... Am I missing ways that <img src="..."> better (or equally) achieves the goal, or is my determination of the goal incorrect, or is this sensible? (My interpretation of the current HTML5 spec is that alt="External image" would be non-conforming, because it does not serve as a substitute for the image - it serves only as a marker for the image and an indicator that the image is 'external'. The spec should not be so strict in what the alt text must be, else it force sites like this to compromise their user experience in order to achieve conformance.) -- Philip Taylor pjt47@cam.ac.uk
Received on Saturday, 3 May 2008 19:51:10 UTC