WebAIM - Web Accessibility In Mind

E-mail List Archives

Re: ALT Text - CMS Problem

for

From: Jukka K. Korpela
Date: Apr 14, 2011 11:30PM


David Ashleydale wrote:

> We have a content management system at work that forces users to enter
> non-null ALT text for every image on a web page -- even images that
> are deemed "decorative".
>
> First, do you think I should get them to fix this system so that
> users can choose whether an image gets ALT text or null ALT text?

I guess you mean "non-null ALT text or null ALT text". Yes, this should be
fixed, of course.

> One of the potential problems with doing that is it might result in
> meaningful images getting null ALT text because the page authors
> could then just "skip them" by choosing null.

The problem is very real, but preventing authors from doing the right thing
in many cases is an unacceptable cost for urging them to consider things in
other cases.

> Since we are now
> forcing page authors to think about ALT text,

It is impossible to force people to think. You can only force them to some
behavior. For example, to hit the "X" key whenever they are required to type
some text.

> they're at least trying
> and they cannot proceed without assigning ALT text to every image.

This may force them to enter random, absurd, or otherwise completely wrong
ALT text, even when they are willing to think but cannot understand what is
expected or what might be a good ALT text. Lack of ALT text is a lesser evil
than seriously wrong ALT text.

I wonder if the following strategy would bee "too clever":
In the authoring tool, include an optional field for "role", preferably with
a dropdown for selecting a value as per ARIA proposal (allowing an empty
value, too, so that the field can removed too). Do not let the author
proceed if ALT text is set to empty, unless "role" has the value
"presentation".

> Second, if we do leave the system the way it is, what are some good
> guidelines to give to page authors when they are confronted with
> having to come up with ALT text for decorative images? I'm sure "keep
> it short" is one good tip -- any others?

No, "make it blank" is best. I presume that by "null ALT text" you mean an
ALT attribute with the empty string "" as its value. The value " " is
non-null then. If the CMS doesn't allow a value consisting of a space (or
spaces) only, then you might try the no-break space. The method for entering
it depends on the authoring tool and environment; Ctrl+space might work, or
it might not, and so might typing  . If even this won't work, I'd use
some punctuation-like character, like "-", that should not disturb too
much, whether displayed or spoken ("hyphen", "dash").

--
Yucca, http://www.cs.tut.fi/~jkorpela/