Pages

Jan 23, 2011

Alt text for Web Accessibility

I was once given a traffic tip that I should always include an alternative text, or let me call it an alt attribute, in the HTML for my images. As a result, I have been doing this ever since.


What they Hardly Say
But there is something the guru didn't tell me, something that I had to learn on my own. The alt attribute is used in HTML and XHTML documents to specify alternative text that is to be rendered when the element to which it is applied cannot be rendered. It is specified for several non-textual elements including img, area, applet and input, where it must be specified for the first two and optional for the last two.

Why you should Provide for alt text
Specifying alt text assist different users. Just to mention a few, alt text assists:


  1. Users without graphic display terminals.

  2. Users whose browsers don't support forms.

  3. Visually impaired users.

  4. Users who use speech synthesizers.

  5. Users who have configured their graphical user agents not to display images.

This means that when alt text is provided for, the elements can be accessible to everyone including:


  • The disabled, for instance, the blind.

  • People in rural areas with low bandwidth who turned the images off to speed download.

  • People who turned off images on their mobile phones to lower bandwidth charges.

  • And equally important, accessible to technologies that cannot see images such as the search engines.

A common misconception : Alt attribute is not supposed to literally describe contents of the element; it is supposed to be an alternative for the element.

No comments: