WebAIM - Web Accessibility In Mind

E-mail List Archives

Re: Images src has empty alt tag, but has a title, what to advise?

for

From: Jared Smith
Date: Oct 26, 2011 3:45AM


On Mon, Oct 24, 2011 at 6:52 PM, Birkir R. Gunnarsson wrote:

> I am reviewing a webpage with a lot of alt text issues.

Indeed. The markup you presented is pretty messed up. The <h3> appears
in markup after an image that it describes. There are two adjacent
links to the same location. There are title attribute values defined
that wouldn't be provided to the user or that are redundant to visual
text. It seems really odd to have a heading inside a list item. Etc.

The biggest question is whether the 2nd link's text adequately
provides the alternative for the image. If so, then as Priti notes,
combining everything into one link and (possibly) heading will do the
job. Something like this (code greatly simplified):

<h3><a href="/frett/ras-1/saelkeraferd-listanna"><img
src="voluspa_salur_0.jpg" alt="" />Sælkeraferð listanna<a/></h3>
<div>Völuspá í Norræna húsinu er sælkeraferð fyrir öll skilningarvitin.</div>

Not understanding the content, this seems to be more appropriate. Of
course you could use CSS and maybe line breaks to get the same visual
presentation. If the title text is useful advisory information, but
not redundant with visible text, it could be added to the link or the
image as appropriate. This title text wouldn't be available to anyone
except sighted mouse users that happen to hover the mouse over the
image.

Jared