Element

img

Error Type

Likely

Guidelines

  • Section 508
    Guideline GroupA - text equivalents
  • Stanca Act
    Guideline GroupRequirement 3: Text Equivalents
  • Visual Content
    Guideline Group[ _GROUPNAME_90 ]
  • WCAG 2.0 (Level A)
    Guideline Group1.1 Text Altrernatives: Provide text alternatives for any non-text content
    Guideline SubgroupSuccess Criteria 1.1.1 Non-text Content (A)
  • WCAG 2.0 (Level AA)
    Guideline Group1.1 Text Alternatives: Provide text alternatives for any non-text content
    Guideline SubgroupSuccess Criteria 1.1.1 Non-text Content (A)
  • WCAG 2.0 (Level AAA)
    Guideline Group1.1 Text Alternatives: Provide text alternatives for all non-text content
    Guideline SubgroupSuccess Criteria 1.1.1 Non-text Content (A)
  • WCAG SRWSD

Requirement

Alt text is not the same as the filename unless author has confirmed it is correct.

Error

Image has suspicious Alt text (same as filename).

Short Description

img element cannot have alt attribute value that is the same as its src attribute.

Rationale

Alt text should describe the image. This Alt text is suspicious because it may be just placeholder text.

How To Determine

Question Is this Alt text appropriate for the image?
PASS Alt text is appropriate for the image.
FAIL Alt text is not appropriate for the image.

Steps To Check

Procedure

1. Check each img element and compare its alt attribute value to its src attribute value.

Expected Result

1. The alt attribute value and the src attribute values are expected to be different.

Failed Result

1. If both values are the same then view the image and determine if the alt attribute value is appropriate.

Examples

Pass Examples

Alt text is different from src attribute.
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN""http://www.w3.org/TR/REC-html40/loose.dtd">
<html lang="en">
<head>
<title>OAC Testfile - Check #2 - Negative</title>
</head>
<body>
<img src="rex.jpg" alt="photo of rex the cat"/>
</body>
</html>

Fail Examples

Alt text is the same as src attribute.
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN""http://www.w3.org/TR/REC-html40/loose.dtd">
<html lang="en">
<head>
<title>OAC Testfile - Check #2 - Positive</title>
</head>
<body>
<img src="rex.jpg" alt="rex.jpg"/>
</body>
</html>

English | German | Italiano


Web site engine's code is copyright © 2011
Inclusive Design Institute
Web Service API