Validome-Logo

HTML / XHTML / WML / XML Validator

 
Validome - Validator Home de | en
Validome-Logo

Error-documents regarding Text-Anchors


Validating Anchors is based on the following specifications:
1. Specifying Anchors and links
2. Fragment Identifiers


  Validome W3C-Validator WDG-Validator Total-Validator Site Valet-Validator

HTTP-Header:
Content-Type: text/html; charset=ISO-8859-1

  1: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
  2:      "http://www.w3.org/TR/html4/loose.dtd">
  3: 
  4: <html>
  5:   <head>
  6:     <title>Syntax error in Anchorname</title>
  7:     <meta http-equiv="Content-Type" content="text/html;
  8:           charset=iso-8859-1">
  9:   </head>
 10:   <body>
 11:     <a href="#anchor1">anchor1</a>
 12:     
 13:     <a name="anchor1" id="anchor2"></a>
 14:   </body>
 15: </html>

"name"- and "id"-Attribute have to contain identical values. Here it isn't so.

  Validome W3C-Validator WDG-Validator Total-Validator Site Valet-Validator

HTTP-Header:
Content-Type: text/html; charset=ISO-8859-1

  1: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
  2:      "http://www.w3.org/TR/html4/loose.dtd">
  3: 
  4: <html>
  5:   <head>
  6:     <title>Syntax error in Anchorname</title>
  7:     <meta http-equiv="Content-Type" content="text/html;
  8:           charset=iso-8859-1">
  9:   </head>
 10:   <body>
 11:     <a href="#8anchor1">anchor1</a>
 12:     
 13:     <a id="8anchor1"></a>
 14:   </body>
 15: </html>

Syntax Errors in Anchorname (id-Attribute).
The first character has to be alphabetic, after that numeric ones and the special characters underline "_", hyphen "-", colon ":" and full stop "." are allowed too.

  Validome W3C-Validator WDG-Validator Total-Validator Site Valet-Validator

HTTP-Header:
Content-Type: text/html; charset=ISO-8859-1

  1: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
  2:      "http://www.w3.org/TR/html4/loose.dtd">
  3: 
  4: <html>
  5:   <head>
  6:     <title>Entity in Anchorname</title>
  7:     <meta http-equiv="Content-Type" content="text/html;
  8:           charset=iso-8859-1">
  9:   </head>
 10:   <body>
 11:     <a href="#ENTITY-&Ouml;">anchor1</a>
 12:     <a href="#ENTITY-&#196;">anchor2</a><p>
 13:     <a href="#ENTITY-&#xDC;">anchor3</a>
 14:     
 15:     <a name="ENTITY-&Ouml;"></a>
 16:     <a name="ENTITY-&#196;"></a>
 17:     <a name="ENTITY-&#xDC;"></a>
 18:     
 19:     <a href="#ENTITY-&#48;">anchor4</a><p>
 20:     <a href="#entity-&#x31;">anchor5</a>
 21:     
 22:     <a id="ENTITY-&#48;"></a>
 23:     <a id="entity-&#x31;"></a>
 24:   </body>
 25: </html>

Anchornames which are defined in a "name"-Attribute may contain Entities.
But it is not allowed, if the Anchorname is defined in an "id"-Attribute.

  Validome W3C-Validator WDG-Validator Total-Validator Site Valet-Validator

HTTP-Header:
Content-Type: text/html; charset=ISO-8859-1

  1: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
  2:      "http://www.w3.org/TR/html4/loose.dtd">
  3: 
  4: <html>
  5:   <head>
  6:     <title>Anchor conflict</title>
  7:     <meta http-equiv="Content-Type" content="text/html;
  8:           charset=iso-8859-1">
  9:   </head>
 10:   <body>
 11:     <a href="#name1">name1</a>
 12:     <a href="#name2">name2</a>
 13:     <a href="#name3">name3</a>
 14:     <a href="#name4">name4</a>
 15:     
 16:     <form action="" name="name1">
 17:       <a name="name1"></a>
 18:       <a id="name2"></a>
 19:       <a id="name1" name="name1"></a>
 20:       <a name="name2"></a>
 21:       <a id="name3"></a>
 22:       <a name="name3"></a>
 23:       <a name="name4"></a>
 24:             
 25:       <input name="name2" type="text">
 26:     </form>
 27:     <p id="name4">
 28:   </body>
 29: </html>

Anchornames may be defined in "name"- as well as in "id"-Attributes.
But each Anchorname may occur only once per document.

  Validome W3C-Validator WDG-Validator Total-Validator Site Valet-Validator

HTTP-Header:
Content-Type: text/html; charset=ISO-8859-1

  1: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
  2:      "http://www.w3.org/TR/html4/loose.dtd">
  3: 
  4: <html>
  5:   <head>
  6:     <title>missing Anchor</title>
  7:     <meta http-equiv="Content-Type" content="text/html;
  8:           charset=iso-8859-1">
  9:   </head>
 10:   <body>
 11:     <a href="#anchor1">anchor1</a>
 12:     <a href="#anchor2">anchor2</a>
 13:     <a href="#anchor3">anchor3</a>
 14:     <a href="#anchor4">anchor4</a>
 15:           
 16:     <a name="anchor1"></a>
 17:     <a id="anchor2"></a><p>
 18:     <div id="anchor3">anchor3</div>
 19:   </body>
 20: </html>

Anchors where links point to should be checked to exist and be reported if not.

  Validome W3C-Validator WDG-Validator Total-Validator Site Valet-Validator

HTTP-Header:
Content-Type: text/html; charset=ISO-8859-1

  1: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
  2:      "http://www.w3.org/TR/html4/loose.dtd">
  3: 
  4: <html>
  5:   <head>
  6:     <title>missing Anchor</title>
  7:     <meta http-equiv="Content-Type" content="text/html;
  8:           charset=iso-8859-1">
  9:   </head>
 10:   <body>
 11:     <a href="#ANCHOR1">anchor1</a>
 12:     <a href="#ANCHOR2">anchor1</a>
 13:           
 14:     <a name="anchor1"></a>
 15:     <a id="anchor2"></a>
 16:   </body>
 17: </html>

Links to Anchors and the Anchornames should not differ in upper and lower case.

  Validome W3C-Validator WDG-Validator Total-Validator Site Valet-Validator

HTTP-Header:
Content-Type: text/html; charset=UTF-8

  1: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
  2:      "http://www.w3.org/TR/html4/loose.dtd">
  3: 
  4: <html>
  5:   <head>
  6:     <title>Invalid char in URI</title>
  7:     <meta http-equiv="Content-Type" content="text/html;
  8:           charset=utf-8">
  9:   </head>
 10:   <body>
 11:     <a href="http://مثال.إختبار">test</a>
 12:   </body>
 13: </html>

Allowed is only a subset of ASCII characters (RFC-3986 )

Top   v3.0.0 - 16.11.2010 © validome.org - all rights reserved Datenschutzerklärung

Valid XHTML 1.0