Element

body

Error Type

Potential

Guidelines

Requirement

The reading direction of all text is correctly marked.

Error

The reading direction of all text may not be correctly marked

Short Description

The reading direction of all text is correctly marked.

How To Determine

Question Is the reading direction of all text correctly marked?
PASS The reading direction of all text is correctly marked.
FAIL The reading direction of all text is not correctly marked.

Steps To Check

Procedure

1. Examine the reading direction of text in the document.
2. If the reading direction is right-to-left, check that for the nearest parent element that has a dir attribute, the attribute has the value "rtl".
3. If the reading direction is left-to-right, check that there is no parent element with a dir attribute, or that for the nearest parent element that has a dir attribute, the attribute has the value "ltr".

Expected Result

1. Steps #2 and #3 are true for all text.

Failed Result

1. Modify the dir attribute values so they correctly reflect the text reading direction.

Examples

Pass Examples

Primary document text reads left to right and contains a section that reads right to left that is unmarked.
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/xhtml; charset=UTF-8" />
<title>Testfile - Check #235.2 - Negative</title>
</head>
<body>    
<p>Normal body text goes here</p>
<blockquote lang="he" dir="rtl"> 
<!-- Hebrew quote goes here -->  
<blockquote> 
</body>
</html>

Fail Examples

Primary document text reads left to right and contains a section that reads right to left but is unmarked.
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/xhtml; charset=UTF-8" />
<title>Testfile - Check #235.1 - Positive</title>
</head>
<body>
<p>Normal body text goes here</p>
<blockquote lang="he"> 
<!-- Hebrew quote goes here -->  
<blockquote> 
</body>
</html>

English | German | Italiano


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