WebAIM - Web Accessibility In Mind

E-mail List Archives

Thread: alt text on img sources, and best software to inspect html code with a screen reader

for

Number of posts in this thread: 7 (In chronological order)

From: Birkir R. Gunnarsson
Date: Mon, Oct 31 2011 8:57AM
Subject: alt text on img sources, and best software to inspect html code with a screen reader
No previous message | Next message →

Happy Halloween ladies and gentlemen.

I am fighting a consistent lack of understanding of alt tags within
image sources to links.
If someone can help me on the pat towards enlightenment in this area,
it would be most appreciated.
The example I am analyzing can be found here:
http://www.rikisendurskodun.is/frettir/nanar/article/erfitt-ad-meta-arangur-rammasamninga-um-innkaup.html

There is a headline (heading level 1). Right after that is a link to a picture
pics/e2c148...
Jaws recognizes this as a link,, and reads it, with the name of the image i.e.
"graphic link pics/e2c1...."
The image itself has both alt and title tags set to ""
What would be the correct way to code this link to hide it from screen
readers altogether?
I think I am being confuse by all the Javascript code and IDs I have
to weigh through, making the code a mess to inspect with a screen
reader.
If anyone uses a screen reader to inspect html code, definitely let me
know what you are using in order to do so most effectively.
I will be setting up VS 2010 tomorrow, and I am hoping it will help.
Thanks
-Birkir

From: Jared Smith
Date: Mon, Oct 31 2011 9:09AM
Subject: Re: alt text on img sources, and best software to inspect html code with a screen reader
← Previous message | Next message →

On Mon, Oct 31, 2011 at 8:59 AM, Birkir R. Gunnarsson
< = EMAIL ADDRESS REMOVED = > wrote:

> What would be the correct way to code this link to hide it from screen
> readers altogether?

You can't. JAWS will always identify links. Sighted users can see
something and click on it, so JAWS properly identifies this function.
If there's no alternative text to be read, it will, as you note, read
the image file name - in this case "e2c1488c83.jpg", which is worse
than useless.

This link doesn't really provide much utility - it links to the image
itself. The link could probably be removed. If it remains, the image
must be given alternative text that describes the content and function
of the link, probably "larger image of {image content}" or similar.

Jared

From: Bryan Garaventa
Date: Mon, Oct 31 2011 9:30AM
Subject: Re: alt text on img sources, and best software to inspect html code with a screen reader
← Previous message | Next message →

Actually if you wanted to provide an image link to sighted users that has no
value or relevance to screen reader users, you could hide it in the
following manner:

<span class="link"><img src="whatever.jpg" alt="" ... /></span>

Then use CSS to style the span like a link and make it clickable. Screen
readers will ignore the image since it has a null alt, keyboard users won't
encounter it since it has no tabindex, and the span won't be recognized by
ATs as an active element.

It's best to make certain that such functionality is totally useless to AT
and keyboard users before doing it though, otherwise you would be
introducing equivalence issues.


----- Original Message -----
From: "Jared Smith" < = EMAIL ADDRESS REMOVED = >
To: "WebAIM Discussion List" < = EMAIL ADDRESS REMOVED = >
Sent: Monday, October 31, 2011 8:08 AM
Subject: Re: [WebAIM] alt text on img sources, and best software to inspect
html code with a screen reader


> On Mon, Oct 31, 2011 at 8:59 AM, Birkir R. Gunnarsson
> < = EMAIL ADDRESS REMOVED = > wrote:
>
>> What would be the correct way to code this link to hide it from screen
>> readers altogether?
>
> You can't. JAWS will always identify links. Sighted users can see
> something and click on it, so JAWS properly identifies this function.
> If there's no alternative text to be read, it will, as you note, read
> the image file name - in this case "e2c1488c83.jpg", which is worse
> than useless.
>
> This link doesn't really provide much utility - it links to the image
> itself. The link could probably be removed. If it remains, the image
> must be given alternative text that describes the content and function
> of the link, probably "larger image of {image content}" or similar.
>
> Jared
>

From: deborah.kaplan@suberic.net
Date: Mon, Oct 31 2011 9:39AM
Subject: Re: alt text on img sources, and best software to inspect html code with a screen reader
← Previous message | Next message →

Bryan Garaventa wrote:

> It's best to make certain that such functionality is totally useless to AT and keyboard users before doing it though, otherwise you would be introducing equivalence issues.

And the only reason the functionality would be totally useless to
keyboard users if the link went to something that was totally
inaccessible via keyboard, like some kind of mouse driven app.
Even then, a lot of keyboard users can pull up mouse equivalents
in a pinch if necessary (e.g. by using mouse keys or Dragon's
mousegrid), so hiding things from keyboard users is generally not
a good plan.

-Deborah

From: Accessibility India
Date: Mon, Oct 31 2011 9:45AM
Subject: Re: alt text on img sources, and best software to inspect html code with a screen reader
← Previous message | Next message →

On 10/31/11, Bryan Garaventa < = EMAIL ADDRESS REMOVED = > wrote:
> Actually if you wanted to provide an image link to sighted users that has no
> value or relevance to screen reader users, you could hide it in the
> following manner:
>
> <span class="link"><img src="whatever.jpg" alt="" ... /></span>
>
> Then use CSS to style the span like a link and make it clickable. Screen
> readers will ignore the image since it has a null alt, keyboard users won't
> encounter it since it has no tabindex, and the span won't be recognized by
> ATs as an active element.
Screen readers will recognize clickable elements when navigated
through the web page. The screen reader user will be confused if the
clickable element is not provided with the target.
>
> It's best to make certain that such functionality is totally useless to AT
> and keyboard users before doing it though, otherwise you would be
> introducing equivalence issues.
>

From: Bryan Garaventa
Date: Mon, Oct 31 2011 10:18AM
Subject: Re: alt text on img sources, and best software to inspect html code with a screen reader
← Previous message | Next message →

"Screen readers will recognize clickable elements when navigated through the
web page. The screen reader user will be confused if the clickable element
is not provided with the target."

True enough, however if you use onMouseUp instead of onClick, screen
readers will not recognize this.

----- Original Message -----
From: "Accessibility India" < = EMAIL ADDRESS REMOVED = >
To: "WebAIM Discussion List" < = EMAIL ADDRESS REMOVED = >
Sent: Monday, October 31, 2011 8:37 AM
Subject: Re: [WebAIM] alt text on img sources, and best software to inspect
html code with a screen reader


> On 10/31/11, Bryan Garaventa < = EMAIL ADDRESS REMOVED = > wrote:
>> Actually if you wanted to provide an image link to sighted users that has
>> no
>> value or relevance to screen reader users, you could hide it in the
>> following manner:
>>
>> <span class="link"><img src="whatever.jpg" alt="" ... /></span>
>>
>> Then use CSS to style the span like a link and make it clickable. Screen
>> readers will ignore the image since it has a null alt, keyboard users
>> won't
>> encounter it since it has no tabindex, and the span won't be recognized
>> by
>> ATs as an active element.
> Screen readers will recognize clickable elements when navigated
> through the web page. The screen reader user will be confused if the
> clickable element is not provided with the target.
>>
>> It's best to make certain that such functionality is totally useless to
>> AT
>> and keyboard users before doing it though, otherwise you would be
>> introducing equivalence issues.
>>
>

From: Bryan Garaventa
Date: Mon, Oct 31 2011 10:24AM
Subject: Re: alt text on img sources, and best software to inspect html code with a screen reader
← Previous message | No next message

Exactly, this is only useful in extremely rare circumstances.

----- Original Message -----
From: < = EMAIL ADDRESS REMOVED = >
To: "WebAIM Discussion List" < = EMAIL ADDRESS REMOVED = >
Sent: Monday, October 31, 2011 8:40 AM
Subject: Re: [WebAIM] alt text on img sources, and best software to inspect
html code with a screen reader


> Bryan Garaventa wrote:
>
>> It's best to make certain that such functionality is totally useless to
>> AT and keyboard users before doing it though, otherwise you would be
>> introducing equivalence issues.
>
> And the only reason the functionality would be totally useless to
> keyboard users if the link went to something that was totally
> inaccessible via keyboard, like some kind of mouse driven app.
> Even then, a lot of keyboard users can pull up mouse equivalents
> in a pinch if necessary (e.g. by using mouse keys or Dragon's
> mousegrid), so hiding things from keyboard users is generally not
> a good plan.
>
> -Deborah
>