This Wiki page is edited by participants of the HTML Accessibility Task Force. It does not necessarily represent consensus and it may have incorrect information or information that is not supported by other Task Force participants, WAI, or W3C. It may also have some very useful information.


From HTML accessibility task force Wiki
Jump to: navigation, search

Change the Generator Mechanism for img from Document Level to Element Level

Bug Number


Bug Title

The Generator Mechanism for img Should Change from Document Level to Element Level

Spec Section

Guidance for conformance checkers [1]

As one of the options in the list of conformance checker validity checks, the editor's draft currently says:

A conformance checker must report the lack of an alt attribute as an error unless one of the conditions listed below applies...

  • The document has a meta element with a name attribute whose value is an ASCII case-insensitive match for the string "generator". (This case does not represent a case where the document is conforming, only that the generator could not determine appropriate alternative text — validators are required to not show an error in this case to discourage markup generators from including bogus alternative text purely in an attempt to silence validators.)

Bug Description

The generated mechanism should only be included at the element level with a detection method like a "generated" attribute, rather than the document level.

If the generated option is left at document level, as in the current editor's draft, it would be too easy for authors just to tag the document "generated" and then forget to provide any text alternatives for images.

Generated Example

  1. Author logs into the photo sharing site
  2. Author uses the uploader feature to upload 50 pics of a vacation (XYZ0001.png, XYZ0002.png,..., XYZ0050.png) into an album the author calls "Paris 2009".
  3. A prompt appears asking the author to write descriptive labels for each image to facilitate text searching and access by people with disabilities.
  4. The author logs off without adding individual text alternatives.
  5. The photo sharing site assigns the @alt strings "Photo 1 of 50 of album Paris 2009"
  6. The author logs back in they still see "generated" indicators on the images and/or the album that reminds them that the images are still lacking descriptive labels.
  7. The page will be HTML5_valid because it includes @alt
  8. The feature will meet the proposed ATAG2 requirement because the "After authoring session ended" repair used contextual information not available to the user agent.
  9. The page will NOT meet WCAG 2.0 because the text alternative does not serve the equivalent purpose.

Source: ATAG2 B.2.4 Assist authors to manage, edit, and reuse equivalent alternatives for non-text objects - Jan Richards[2]

Outcomes of Fixing the Bug

Outcomes of creating a "generator" attribute include:

  • Enables tools to programmatically determine [3] where text alternatives are needed and allow for future improvement. It would provide a practical method of detection and handling.
  • Identifies/stamps any metadata repair as indeed a metadata repair. This makes it clear it is a machine-generated patch-job and not a human-generated text alternative. The two aren't the same and shouldn't be confused or on purpose or otherwise.
  • Is harmony with proposed Authoring Tool Accessibility Guideline (ATAG) 2.0 B.2.4. [4]
  • Is in accord with Accessibility Coordination Group's "Consensus Resolutions on Text alternatives in HTML 5". [5].


HTML5 Issue and Change Proposal

This is associated with HTML TRACKER ISSUE-31:

Change Proposal - Replace img Guidance for Conformance Checkers: