Element

pre

Error Type

Potential

Guidelines

  • WCAG 2.0 (Level A)
    Guideline Group1.3 Ensure that information and structure can be separated from presentation
    Guideline SubgroupSuccess Criteria 1.3.1 Info and Relationships (A)
  • WCAG 2.0 (Level AA)
    Guideline Group1.3 Adaptable: Create content that can be presented in different ways (for example simpler layout) without losing information or structure.
    Guideline SubgroupSuccess Criteria 1.3.1 Info and Relationships (A)
  • WCAG 2.0 (Level AAA)
    Guideline Group1.3 Adaptable: Create content that can be presented in different ways without losing information or structure.
    Guideline SubgroupSuccess Criteria 1.3.1 Info and Relationships (A)

Requirement

pre element should not be used to create tabular layout.

Error

pre element may be misused to create tabular layout.

Short Description

This error is generated for each pre element.

How To Determine

Question Is this pre element used to create tabular layout?
PASS pre is not used to create tabular layout.
FAIL pre is used to create tabular layout.

Steps To Check

Procedure

1. Check the contents of all pre elements in the document.

Expected Result

1. pre elements should not be used to created tabular layout.

Failed Result

1. Remove the pre element and replace it with table elements.

Examples

Pass Examples

pre not used.
<!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 #154 - Positive</title>
</head>
<body>
</body>
</html>

Fail Examples

pre used.
<!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 #154 - Positive</title>
</head>
<body>

<pre>
     dogs  cats
big	  2     4
small 5     7
</pre>

</body>
</html>

English | German | Italiano


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