Element

body

Error Type

Known

Guidelines

  • WCAG 2.0 (Level A)
    Guideline Group1.4 Distinguishable: Make it easier for users to see and hear content including separating foreground from background.
    Guideline SubgroupSuccess Criteria 1.4.1 Use of Color (A)
  • WCAG 2.0 (Level AA)
    Guideline Group1.4 Distinguishable: Make it easier for users to see and hear content including separating foreground from background.
    Guideline SubgroupSuccess Criteria 1.4.1 Use of Color (A)
  • WCAG 2.0 (Level AAA)
    Guideline Group1.4 Distinguishable: Make it easier for users to see and hear content including separating foreground from background.
    Guideline SubgroupSuccess Criteria 1.4.1 Use of Colour (A)
  • WCAG SRWSD

Requirement

All text colors or no text colors are set.

Error

All text colors are not set.

Short Description

If the author specifies that the text must be black, then it may override the settings of the user agent and render a page that has black text (specified by the author) on black background (that was set in the user agent).

How To Repair

Ensure all the text colors or none of the text colors are set using attributes on the body element.

Repair Example

<body color="#000000" link="#330000" alink="#003300" vlink="#000033" bgcolor="#ffffff">

Steps To Check

Procedure

1. Check the body element and determine if it contains any of the text colors color, bgcolor, vlink, alink or link.

Expected Result

1. All text colors or no text colors are set.

Failed Result

1. Add all the color attributes or remove all the color attributes from the body element.

Examples

Pass Examples

All text colors are set.
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html lang="en">
<head>
<title>ATRC Testfile - Check #252.2 - Negative</title>
</head>
<body bgcolor="#ffffff" text="#000000" link="#000000" vlink="#000000" alink="#000000">
<p>This is some example text.</p>
</body>
</html>

Fail Examples

The text color and background color are set but other colors are not set.
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html lang="en">
<head>
<title>ATRC Testfile - Check #252.1 - Positive</title>
</head>
<body bgcolor="#ffffff" text="#000000">
<p>This is some example text.</p>
</body>
</html>

English | German | Italiano


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