summaryrefslogtreecommitdiffstats
path: root/htdocs/docs/errors.html
diff options
context:
space:
mode:
authorlink <link@localhost>2003-05-24 20:32:50 +0000
committerlink <link@localhost>2003-05-24 20:32:50 +0000
commitad55505ac9e7be6346dc97f3f0f0082e9b4e88be (patch)
treec5d3f870a93a3ad458a7fd9d91b82a27291cc188 /htdocs/docs/errors.html
parentb6cb0baa3d77fad45374094a80c23629e59934a3 (diff)
downloadmarkup-validator-ad55505ac9e7be6346dc97f3f0f0082e9b4e88be.zip
markup-validator-ad55505ac9e7be6346dc97f3f0f0082e9b4e88be.tar.gz
markup-validator-ad55505ac9e7be6346dc97f3f0f0082e9b4e88be.tar.bz2
Merging from validator-0_6_0-branch, at tag validator-0_6_2-beta1, to HEAD.
Diffstat (limited to 'htdocs/docs/errors.html')
-rwxr-xr-xhtdocs/docs/errors.html1377
1 files changed, 612 insertions, 765 deletions
diff --git a/htdocs/docs/errors.html b/htdocs/docs/errors.html
index 00b751c..b819f13 100755
--- a/htdocs/docs/errors.html
+++ b/htdocs/docs/errors.html
@@ -1,5 +1,5 @@
-<!--#set var="revision" value="\$Id: errors.html,v 1.25 2003-02-24 23:33:19 ville Exp $"
---><!--#set var="date" value="\$Date: 2003-02-24 23:33:19 $"
+<!--#set var="revision" value="\$Id: errors.html,v 1.26 2003-05-24 20:32:46 link Exp $"
+--><!--#set var="date" value="\$Date: 2003-05-24 20:32:46 $"
--><!--#set var="title" value="Error Explanations for The W3C Markup Validation Service"
--><!--#set var="relroot" value="../"
--><!--#include virtual="../header.html" -->
@@ -9,770 +9,617 @@
and are used here with his permission.
</p>
-<div id="toc">
-<h2 id="TableOfContents">Table of Contents</h2>
-<ul>
-
-<li><a href="#undef-id">
-&ldquo;ID &lsquo;<var>FOO</var>&rsquo; already defined&rdquo;
-</a></li>
-
-<li><a href="#unterm-comment-1">
-&ldquo;entity end not allowed in comment&rdquo;
-</a></li>
-
-<li><a href="#unterm-comment-2">
-&ldquo;name start character invalid: only s and comment allowed in comment declaration&rdquo;
-</a></li>
-
-<li><a href="#bad-comment">
-&ldquo;unknown declaration type &lsquo;<var>FOO</var>&rsquo;&rdquo;
-</a></li>
-
-<li><a href="#attr-quoted">
-&ldquo;an attribute value must be a literal unless it contains only name characters&rdquo;
-</a></li>
-
-<li><a href="#attr-char">
-&ldquo;character `X' not allowed in attribute specification list&rdquo;
-</a></li>
-
-<li><a href="#name-length">
-&ldquo;length of attribute value must not exceed LITLEN less NORMSEP (1022)&rdquo;
-</a></li>
-
-<li><a href="#undef-tag">
-&ldquo;element &lsquo;<var>FOO</var>&rsquo; undefined&rdquo;
-</a></li>
-
-<li><a href="#not-allowed">
-&ldquo;document type does not allow element &lsquo;<var>FOO</var>&rsquo; here&rdquo;
-</a></li>
-
-<li><a href="#not-contained">
-&ldquo;document type does not allow element &lsquo;<var>FOO</var>&rsquo; here; assuming missing &lsquo;<var>BAR</var>&rsquo; start-tag&rdquo;
-</a></li>
-
-<li><a href="#attr-undef">
-&ldquo;there is no attribute &lsquo;<var>FOO</var>&rsquo; for this element (in this HTML version)&rdquo;
-</a></li>
-
-<li><a href="#undef-attr-val">
-&ldquo;&lsquo;<var>FOO</var>&rsquo; is not a member of the group specified in the declared value of this attribute&rdquo;
-</a></li>
-
-<li><a href="#bad-attr-char">
-&ldquo;syntax of attribute value does not conform to declared value&rdquo;
-</a></li>
-
-<li><a href="#attr-bad-name">
-&ldquo;value of attribute &lsquo;<var>FOO</var>&rsquo; invalid: "#" cannot start a name&rdquo;
-</a></li>
-
-<li><a href="#bad-abbrev-attr">
-&ldquo;&lsquo;<var>FOO</var>&rsquo; is not a member of a group specified for any attribute&rdquo;
-</a></li>
-
-<li><a href="#attr-missing">
-&ldquo;required attribute &lsquo;<var>FOO</var>&rsquo; not specified&rdquo;
-</a></li>
-
-<li><a href="#no-end-tag">
-&ldquo;end tag for &lsquo;<var>FOO</var>&rsquo; omitted, but its declaration does not permit this&rdquo;
-</a></li>
-
-<li><a href="#floating-close">
-&ldquo;end tag for element &lsquo;<var>FOO</var>&rsquo; which is not open&rdquo;
-</a></li>
-
-<li><a href="#omitted-content">
-&ldquo;end tag for &lsquo;<var>FOO</var>&rsquo; which is not finished&rdquo;
-</a></li>
-
-<li><a href="#no-start-tag">
-&ldquo;start tag for &lsquo;<var>FOO</var>&rsquo; omitted, but its declaration does not permit this&rdquo;
-</a></li>
-
-<li><a href="#bad-entity">
-&ldquo;unknown entity &lsquo;<var>FOO</var>&rsquo;&rdquo;
-</a></li>
-
-<li><a href="#bad-char">
-&ldquo;non SGML character number ###&rdquo;
-</a></li>
-
-<li><a href="#unicode-char">
-&ldquo;`####' is not a valid character number&rdquo;
-</a></li>
-
-<li><a href="#bad-pub-id">
-&ldquo;cannot generate system identifier for entity `HTML'&rdquo;
-</a></li>
-
-<li><a href="#missing-subel">
-&ldquo;missing a required sub-element of &lsquo;<var>FOO</var>&rsquo;&rdquo;
-</a></li>
-
-<li><a href="#start-tag">
-&ldquo;start tag was here&rdquo;
-</a></li>
-
-<li><a href="#utf8-bom">
-&ldquo;UTF-8 'BOM' detected and removed&rdquo;
-</a></li>
-
-<li><a href="#text-not-allowed">
-&ldquo; text is not allowed here; try wrapping the text in a more descriptive container&rdquo;
-</a></li>
-
-<li><a href="#unkn-att-val">
-&ldquo; value of attribute &lsquo;<var>FOO</var>&rsquo; cannot be &lsquo;<var>BAR</var>&rsquo;; must be one of &lsquo;<var>FOO</var>&rsquo;, &lsquo;<var>BAR</var>&rsquo;, &lsquo;<var>BAZ</var>&rsquo;&rdquo;
-</a></li>
-
-<li><a href="#no-attr-end">
-&ldquo;character &lsquo;<var>FOO</var>&rsquo; not allowed in attribute specification list possibly caused by a missing quotation mark ending a previous attribute value&rdquo;
-</a></li>
-
-<li><a href="#dup-attr">
-&ldquo;duplicate specification of attribute &lsquo;<var>FOO</var>&rsquo;&rdquo;
-</a></li>
-
-<li><a href="#invalid-attr-val">
-&ldquo;invalid attribute value&rdquo;
-</a></li>
-
-<li><a href="#attr-spec-nmtoken">
-&ldquo;an attribute specification must start with a name or name token&rdquo;
-</a></li>
-
-<li><a href="#inval-comment">
-&ldquo;invalid comment declaration; check your comment syntax&rdquo;
-</a></li>
-
-<li><a href="#assuming-missing-starttag">
-&ldquo;element &lsquo;<var>FOO</var>&rsquo; not allowed here; assuming missing &lsquo;<var>BAR</var>&rsquo; start-tag&rdquo;</a>
-</li>
-</ul>
-</div>
-
-
-<h2>Listing of errors and their explanation</h2>
-
- <dl>
- <dt><a id="undef-id" name="dup-id">&ldquo;<code>ID &lsquo;<var>FOO</var>&rsquo; already defined</code>&rdquo;</a></dt>
- <dd>
- <p>
- You have defined the id/name &lsquo;<var>FOO</var>&rsquo; more then once. You will also get
- a message telling you where it was first defined. Be aware that this
- message may be the result of an ambiguity in the specification.
- While user-agents must treat values of the id attribute
- as case-sensitive, they must still be case-insensitive unique in the
- document. See
- <a href="http://www.w3.org/TR/html4/struct/links.html#h-12.2.1">Section
- 12.2.1 Syntax of anchor names</a> in the HTML 4.01 Recommendation
- for further information.
- </p>
- </dd>
- <dt><a id="unterm-comment-1" name="unterm-comment-1">&ldquo;<code>entity end not allowed in comment</code>&rdquo;</a></dt>
- <dd>
- <p>
- Unterminated comment. The position indicator points to the very end of
- the file, where the problem was detected; to find the beginning of the
- comment, try searching for the last occurrence of
- `<code>&lt;!--</code>' in the document.
- </p>
- </dd>
- <dt><a id="unterm-comment-2" name="unterm-comment-2">&ldquo;<code>name start character invalid: only s and comment allowed in comment declaration</code>&rdquo;</a></dt>
- <dd>
- <p>
- Unterminated comments again. This time, you have a case like:
- </p>
- <pre>
- &lt;!-- This is the first unterminated comment &gt;
- &lt;!-- This is the second one &gt;
- </pre>
- <p>
- The validator (correctly) interprets the `<code>--</code>' in the
- second comment as terminating the first comment, and then interprets
- the text of the second comment as text between comments, which is not
- allowed.
- </p>
- </dd>
- <dt><a id="bad-comment" name="bad-comment">&ldquo;<code>unknown declaration type &lsquo;<var>FOO</var>&rsquo;</code>&rdquo;</a></dt>
- <dd>
- <p>
- Most likely an invalid comment of the form <code>&lt;!invalid
- comment&gt;</code>; the validator is (correctly) attempting to
- interpret it as an <a href="sgml.html#sgml">SGML</a> markup
- declaration.
- </p>
- </dd>
- <dt><a id="attr-quoted" name="attr-quoted">&ldquo;<code>an attribute value must be a literal unless it contains only name characters</code>&rdquo;</a></dt>
- <dd>
- <p>
- You have an attribute whose value needs to be in quotes. If an
- attribute value contains any character other than letters, digits,
- hyphens and periods, it must be enclosed in double quotes (single
- quotes would also be OK from an <a href="sgml.html#sgml">SGML</a>
- standpoint, but some browsers don't recognize them).
- </p>
- </dd>
- <dt><a id="attr-char" name="attr-char">&ldquo;<code>character `X' not allowed in attribute specification list</code>&rdquo;</a></dt>
- <dd>
- <p>
- The validator has found a character inside an HTML tag that isn't
- allowed there. This usually means you didn't put an attribute value in
- quotes when necessary. It also probably means that the character in
- question is not allowed in the value of the attribute at all, or you
- would have received the <a href="#attr-quoted">previous error</a>
- instead. See <a href="#bad-attr-char">below</a> for more information.
- </p>
- <p>
- You can also get in trouble by forgetting the closing quote on an
- attribute. For instance:
- </p>
- <pre>
- &lt;IMG SRC="http://foo.com/fred.gif&gt;
- &lt;IMG SRC="http://foo.com/joe.gif&gt;
- </pre>
- <p>
- The validator will (correctly) interpret this as a SRC value of
- <code>"http://foo.com/fred.gif&gt; &lt;IMG SRC="</code>, and then
- choke on the following `:'. In this case, the position indicator in
- the error message may be several lines below the line with the missing
- quote.
- </p>
- </dd>
- <dt><a id="name-length" name="name-length">&ldquo;<code>length of attribute value must not exceed LITLEN less NORMSEP (1022)</code>&rdquo;</a></dt>
- <dd>
- <p>
- This usually occurs in conjunction with the
- <a href="#attr-char">previous error</a>. It almost always means that
- you've forgotten a closing quote on an attribute value. For instance,
- in:
- </p>
- <pre>
- &lt;IMG SRC="fred.gif&gt;
- &lt;!-- 50 lines of stuff --&gt;
- &lt;IMG SRC="joe.gif"&gt;
- </pre>
- <p>
- The SRC value for the first <code>&lt;IMG&gt;</code> is the entire
- fifty lines of stuff up to the next double quote, which probably
- exceeds the <a href="sgml.html#sgml">SGML</a>-defined length limit for
- HTML string literals. Note that the position indicator in the error
- message points to where the attribute value <em>ended</em> &mdash; in
- this case, the <code>"joe.gif"</code> line.
- </p>
- </dd>
- <dt><a id="undef-tag" name="undef-tag">&ldquo;<code>element &lsquo;<var>FOO</var>&rsquo; undefined</code>&rdquo;</a></dt>
- <dd>
- <p>
- You've used an unknown tag (represented here by &lsquo;<var>FOO</var>&rsquo;). Make sure the
- DTD indicated by your DOCTYPE actually includes this element.
- </p>
- <p>
- If the tag in question is a frame-related tag you must use the
- "Frameset" DTD, and if you use (deprecated) physical markup ("FONT"
- and friends) you must use the "Transitional" DTD.
- </p>
- </dd>
- <dt><a id="not-allowed" name="not-allowed">&ldquo;<code>document type does not allow element &lsquo;<var>FOO</var>&rsquo; here</code>&rdquo;</a></dt>
- <dd>
- <p>
- Straightforward, but not terribly informative. There are a
- <em>lot</em> of different errors that will generate this error
- message:
- </p>
- <ul>
- <li>
- Using an unknown tag. In this case, the next error will be
- <a href="#undef-tag">&ldquo;element &lsquo;<var>FOO</var>&rsquo; undefined"</a>.
- </li>
- <li>
- Using a tag in the wrong place. For instance,
- <code>&lt;TABLE&gt;&lt;TD&gt;blah&lt;/TABLE&gt;</code> will cause
- this error. The trick here is that <code>&lt;TABLE&gt;</code> cannot
- <em>directly</em> contain <code>&lt;TD&gt;</code>'s; it contains
- <code>&lt;TR&gt;</code>'s which contain <code>&lt;TD&gt;</code>'s.
- The above example should be
- <code>&lt;TABLE&gt;&lt;TR&gt;&lt;TD&gt;blah&lt;/TABLE&gt;</code>.
- </li>
- </ul>
- </dd>
- <dt><a id="not-contained" name="not-contained">&ldquo;document type does not allow element &lsquo;<var>FOO</var>&rsquo; here; assuming missing &lsquo;<var>BAR</var>&rsquo; start-tag</a>&rsquo;</dt>
- <dd>
- <p>
- Similar to the <a href="#not-allowed">previous error</a>, but more
- specific: in this case, you have a &lsquo;<var>FOO</var>&rsquo; element that is not contained
- in a &lsquo;<var>BAR</var>&rsquo; element when &lsquo;<var>FOO</var>&rsquo; is not allowed outside of &lsquo;<var>BAR</var>&rsquo;. Some of the
- most common causes of this error are:
- </p>
- <ul>
- <li>
- Using the <code>DD</code> element as a fake paragraph indent.
- <code>DD</code> is not allowed outside of a <code>DL</code> element.
- </li>
- <li>
- Improper construction of a nested list. An inner UL or OL in a
- nested list may not appear directly within an outer UL/OL, but only
- within an LI of the outer UL/OL, as in the following example:
- <pre>
- &lt;OL&gt;
- &lt;LI&gt;Obtain the following items:
- &lt;UL&gt;
- &lt;LI&gt;Ham&lt;/LI&gt;
- &lt;LI&gt;Bread; one of:
- &lt;UL&gt;
- &lt;LI&gt;White&lt;/LI&gt;
- &lt;LI&gt;Rye&lt;/LI&gt;
- &lt;LI&gt;Whole wheat&lt;/LI&gt;
- &lt;/UL&gt;
- &lt;/LI&gt; &lt;!-- End of the "Bread" &lt;LI&gt; --&gt;
- &lt;LI&gt;Cheese&lt;/LI&gt;
- &lt;/UL&gt;
- &lt;/LI&gt; &lt;!-- End of the "Obtain" &lt;LI&gt; --&gt;
- &lt;LI&gt;Place ham and cheese between two slices of bread&lt;/LI&gt;
- &lt;LI&gt;Consume the resulting ham-and-cheese sandwich&lt;/LI&gt;
- &lt;/OL&gt;
- </pre>
- <p>
- The <code>&lt;/LI&gt;</code> end tags are optional and are only
- included above to emphasize how the structure of the nested list
- is arranged; if you omit them, the parser will infer their
- presence in the locations shown above.
- </p>
- </li>
- </ul>
- <p>
- The validator has inserted a &lsquo;<var>BAR</var>&rsquo; start tag where it thinks there needs
- to be one; it will probably complain later on that <a href="#no-end-tag">the
- corresponding end tag is also missing</a>.
- </p>
- </dd>
- <dt><a id="attr-undef" name="attr-undef">&ldquo;<code>there is no attribute &lsquo;<var>FOO</var>&rsquo; for this element (in this HTML version)</code>&rdquo;</a></dt>
- <dd>
- <p>
- You have used an attribute with an element that is defined not to have
- that attribute. This is most commonly caused by using
- vendor-specific attributes without setting the document type
- appropriately.
- </p>
- </dd>
- <dt><a id="undef-attr-val" name="undef-attr-val">&ldquo;<code>&lsquo;<var>FOO</var>&rsquo; is not a member of the group specified in the declared value of this attribute</code>&rdquo;</a></dt>
- <dd>
- <p>
- Similar to the <a href="#attr-undef">previous error</a>; this time,
- you're using an attribute that is defined for the element, but with a
- value that isn't defined for the attribute. For instance, the Netscape
- extension <code>&lt;IMG ALIGN=ABSMIDDLE&gt;</code> will cause this
- error; ABSMIDDLE isn't one of the allowed values for the ALIGN
- attribute of <code>&lt;IMG&gt;</code> (unless, of course, you provided
- a Netscape document type).
- </p>
- <p>
- If you're using the Netscape document type, the BORDER attribute of
- <code>&lt;TABLE&gt;</code> can cause this error.
- </p>
- <p>
- This error can also be caused, oddly enough, by missing close quotes
- on attribute values. For instance, given:
- </p>
- <pre>
- &lt;IMG SRC="fred.gif&gt; &lt;IMG SRC="joe.gif&gt;
- </pre>
- <p>
- The validator will (correctly) see a SRC attribute of
- <code>"fred.gif&gt; &lt;IMG SRC="</code>, and then try to interpret
- JOE.GIF as an attribute of <code>&lt;IMG&gt;</code>.
- </p>
- </dd>
- <dt><a id="bad-attr-char" name="bad-attr-char">&ldquo;<code>syntax of attribute value does not conform to declared value</code>&rdquo;</a></dt>
- <dd>
- <p>
- Yet another attribute error; this time, the attribute in question was
- defined to take a numeric value, or an <a
- href="sgml.html#sgml">SGML</a> identifier value, and you used a
- character that doesn't match what it was expecting.
- </p>
- <p>
- One potentially annoying source of this error is the <code>TD
- WIDTH</code> attribute. Whether intentionally or by oversight, the
- HTML 3.2 DTD defines this attribute to have a value type of NUMBER,
- which means that <code>&lt;TD WIDTH="50%"&gt;</code> is not allowed.
- </p>
- </dd>
- <dt><a id="attr-bad-name" name="attr-bad-name">&ldquo;<code>value of attribute &lsquo;<var>FOO</var>&rsquo; invalid: "#" cannot start a name</code>&rdquo;</a></dt>
- <dd>
- <p>
- A special case of <a href="#bad-attr-char">the previous error</a>; the
- attribute in question is defined to take as value an SGML name token,
- which must begin with a letter.
- </p>
- </dd>
- <dt><a id="bad-abbrev-attr" name="bad-abbrev-attr">&ldquo;<code>&lsquo;<var>FOO</var>&rsquo; is not a member of a group specified for any attribute</code>&rdquo;</a></dt>
- <dd>
- <p>
- Another attribute error, this time referring to an "abbreviated"
- attribute. <a href="sgml.html#sgml">SGML</a> allows you to omit the
- name of an attribute if the attribute value is unambiguous. For
- instance, <code>&lt;IMG ISMAP&gt;</code> is actually an abbreviation
- of <code>&lt;IMG ISMAP=ISMAP&gt;</code>. (Technically, this also means
- that e.g. <code>&lt;P ALIGN=CENTER&gt;</code> could be abbreviated to
- <code>&lt;P CENTER&gt;</code>, but it is unlikely that current
- browsers will get this right.) The validator has found something that
- looks like an abbreviated attribute but doesn't match the value of any
- attribute for this element. For instance, a typo like <code>&lt;IMG
- ISNAP&gt;</code> would produce this error.
- </p>
- <p>
- A missing close quote on a previous attribute value can also trigger
- this error if the next quote it finds is followed by something that
- looks like an abbreviated attribute; for instance, <code>&lt;IMG
- SRC="fred.gif&gt;&lt;IMG SRC="joe.gif&gt;</code> would produce this
- error, referring to the "attribute value" <code>JOE.GIF</code>.
- </p>
- </dd>
- <dt><a id="attr-missing" name="attr-missing">&ldquo;<code>required attribute &lsquo;<var>FOO</var>&rsquo; not specified</code>&rdquo;</a></dt>
- <dd>
- <p>
- You left off a required attribute of the indicated element. The most
- common such omitted attribute is the <code>ALT</code> attribute of the
- <code>AREA</code> or <code>IMG</code> element; browsers will typically
- use these to build a menu equivalent to your client-side image map if
- the user has disabled image loading, so you'll want to use a
- meaningful value here.
- </p>
- </dd>
- <dt><a id="no-end-tag" name="no-end-tag">&ldquo;<code>end tag for &lsquo;<var>FOO</var>&rsquo; omitted, but its declaration does not permit this</code>&rdquo;</a></dt>
- <dd>
- <p>
- You forgot to close something. &lsquo;<var>FOO</var>&rsquo; is the element you forgot to close
- (and the next message, `start tag was here' points to the particular
- instance of &lsquo;<var>FOO</var>&rsquo; in question); the positional indicator points to where
- the validator expected you to close the element. There are a few
- common ways that this can happen:
- </p>
- <ul>
- <li>
- You've put something inside the &lsquo;<var>FOO</var>&rsquo; element that isn't allowed
- there. For instance, <code>&lt;UL&gt;&lt;LI&gt;&lt;H4&gt;fake font
- change&lt;/H4&gt;&lt;/UL&gt;</code> will cause this error, since
- headers aren't allowed inside <code>&lt;UL&gt;</code>'s; the
- validator assumes that you meant to close the
- <code>&lt;UL&gt;</code> before opening the <code>&lt;H4&gt;</code>.
- </li>
- <li>
- Interlocked elements. For instance,
- <code>&lt;B&gt;&lt;I&gt;nope&lt;/B&gt;&lt;/I&gt;</code> will cause
- this error. HTML requires that you close elements &ldquo;inside-out&rdquo;
- &mdash; that is, the last element you opened is the first element you should
- close. In this example, you'd have to close the
- <code>&lt;I&gt;</code> before the <code>&lt;B&gt;</code>.
- </li>
- <li>
- Unclosed <code>&lt;A&gt;</code> tags. Yes, even <code>&lt;A
- NAME="foo"&gt;</code> has to have a corresponding
- <code>&lt;/A&gt;</code>. Note that an empty <code>&lt;A
- NAME&gt;</code> element won't be recognized by some browsers; be
- sure to put at least a word or two inside the
- <code>&lt;A&gt;</code>.
- </li>
- <li>
- Having unadorned text where the validator was expecting a
- sub-element of &lsquo;<var>FOO</var>&rsquo;. For instance, <code>&lt;DL&gt;fake
- indent&lt;/DL&gt;</code> will produce this error, since inside a
- <code>&lt;DL&gt;</code>, the validator only expects to see
- <code>&lt;DT&gt;</code>'s and <code>&lt;DD&gt;</code>'s.
- </li>
- <li>
- A tag of the form <code>&lt;TABLE WIDTH=100%&gt;</code>. The
- previous error should have been that the `%' was <a
- href="#attr-char">"not allowed in attribute specification list"</a>.
- What's happening here is that, in trying to get past the `%', the
- validator has become confused and thinks the `%' is <em>inside</em>
- the <code>&lt;TABLE&gt;...&lt;/TABLE&gt;</code>, thus triggering the
- error message for the previous reason. This error will likely be
- followed by mistaken complaints that your <code>&lt;TR&gt;</code>'s
- are <a href="#not-allowed">"not allowed here"</a>, plus a complaint
- about your <code>&lt;/TABLE&gt;</code> end tag. The solution is to
- put the attribute value in quotes; ie. <code>&lt;TABLE
- WIDTH="100%"&gt;</code>.
- </li>
- </ul>
- <p>
- In general, you should always explicitly close all elements and
- quote all attribute values.
- </p>
- </dd>
- <dt><a id="floating-close" name="floating-close">&ldquo;<code>end tag for element &lsquo;<var>FOO</var>&rsquo; which is not open</code>&rdquo;</a></dt>
- <dd>
- <p>
- The validator found an end tag, represented here by &lsquo;<var>FOO</var>&rsquo;, without a
- corresponding start tag. This frequently occurs in conjunction with
- the <a href="#no-end-tag">previous error</a>. For instance, given
- <code>&lt;B&gt;&lt;I&gt;nope&lt;/B&gt;&lt;/I&gt;</code>, the validator
- will insert a <code>&lt;/I&gt;</code> before the
- <code>&lt;/B&gt;</code>, and then will find the
- <code>&lt;/I&gt;</code> after the <code>&lt;/B&gt;</code> and will
- have nothing to match it with.
- </p>
- <p>
- A subtle variation of this is <code>&lt;P&gt;&lt;H4&gt;fake font
- change&lt;/H4&gt;&lt;/P&gt;</code>. <code>&lt;H4&gt;</code>'s aren't
- allowed inside <code>&lt;P&gt;</code>'s, but since HTML allows you to
- omit the <code>&lt;/P&gt;</code> end tag for paragraphs, the validator
- assumes that you meant <code>&lt;P&gt;&lt;/P&gt;&lt;H4&gt;fake font
- change&lt;/H4&gt;&lt;/P&gt;</code>, in which case the final
- <code>&lt;/P&gt;</code> is indeed superfluous.
- </p>
- <p>
- This error can also be caused by incorrectly supplying an end tag for
- "empty" elements like <code>&lt;HR&gt;</code>, <code>&lt;BR&gt;</code>
- or <code>&lt;IMG&gt;</code>.
- </p>
- </dd>
- <dt><a id="omitted-content" name="omitted-content">&ldquo;<code>end tag for &lsquo;<var>FOO</var>&rsquo; which is not finished</code>&rdquo;</a></dt>
- <dd>
- <p>
- You have a &lsquo;<var>FOO</var>&rsquo; element, but you have omitted some required sub-element
- of it. For instance, a <code>TABLE</code> with no <code>TR</code>'s
- would cause this error.
- </p>
- </dd>
- <dt><a id="no-start-tag" name="no-start-tag">&ldquo;<code>start tag for &lsquo;<var>FOO</var>&rsquo; omitted, but its declaration does not permit this</code>&rdquo;</a></dt>
- <dd>
- <p>
- The validator expected you to start a &lsquo;<var>FOO</var>&rsquo; element at the indicated
- point. This probably means you've put unadorned text somewhere it
- isn't allowed; for instance, <code>&lt;UL&gt;fake
- indent&lt;/UL&gt;</code> will cause this error.
- </p>
- </dd>
- <dt><a id="bad-entity" name="bad-entity">&ldquo;<code>unknown entity &lsquo;<var>FOO</var>&rsquo;</code>&rdquo;</a></dt>
- <dd>
- <p>
- The validator has found an entity (something like
- <code>&amp;this;</code>) that it doesn't recognize. There are a few
- possibilities:
- </p>
- <ul>
- <li>
- <p>
- A reference to a URI that uses <code>&amp;</code> as a separator
- between parameters, such as
- "<code>http://example.org/prog?x=1&amp;y=2</code>".
- </p>
- <p>
- To solve this problem, simply replace all the <code>&amp;</code>'s
- in attribute values with <code>&amp;amp;</code> (user agents will
- convert them back before following the links.)
- </p>
- <p>
- Another way to get around this problem is for the author of the CGI
- program to allow a different value to be used between arguments,
- like ';' or '|', which would allow the link to be coded as e.g.
- <code>&lt;a href="http://example.org/prog?x=1;y=2"&gt;</code>
- </p>
- </li>
- <li>
- An unterminated entity; for instance, <code>this&amp;ampthat</code>
- for "this&amp;that", which the validator (correctly) interprets as a
- request for the entity <code>&amp;ampthat;</code>. Technically, any
- non-alphanumeric character (such as a space) will suffice to
- terminate the entity, but some browsers get this wrong; the safest
- thing to do is to terminate all entities with a semicolon, turning
- our example into <code>this&amp;amp;that</code>.
- </li>
- <li>
- The entity <code>&amp;quot;</code> in conjunction with the HTML 3.2
- <code>DOCTYPE</code>. This entity was <a
- href="http://lists.w3.org/Archives/Public/www-html/1997Mar/0003.html">accidentally
- omitted</a> from the most recent version of the HTML 3.2 DTD. You
- should be able to ignore this error safely, though if you wish, you
- can replace <code>&amp;quot;</code> with the equivalent character
- entity <code>&amp;#34;</code>.
- </li>
- </ul>
- </dd>
- <dt><a id="bad-char" name="bad-char">&ldquo;<code>non SGML character number ###</code>&rdquo;</a></dt>
- <dd>
- <p>
- You've used an illegal character in your text. HTML uses the standard
- ISO8859-1 character encoding, and ISO8859-1 leaves undefined 65
- character codes (0 to 31 inclusive and 127 to 159 inclusive); the
- validator has found one of these undefined characters in your
- document. The character may appear on your browser as a curly quote,
- or a trademark symbol, or some other fancy glyph; on a different
- computer, however, it will likely appear as a completely different
- character, or nothing at all.
- </p>
- <p>
- Your best bet is to replace the character with the nearest equivalent
- ASCII character, or to use an appropriate <a
- href="http://www.w3.org/hypertext/WWW/MarkUp/html3/latin1.html">character
- entity</a>. For more information on ISO8859-1, see <a
- href="http://ppewww.ph.gla.ac.uk/%7Eflavell/aflavell.html">Alan
- Flavell</a>'s excellent <a
- href="http://ppewww.ph.gla.ac.uk/%7Eflavell/iso8859/">ISO8859-1/HTML
- reference</a>.
- </p>
- <p>
- This error can also be triggered by formatting characters embedded in
- documents by some word processors. If you use a word processor to edit
- your HTML documents, be sure to use the "Save as ASCII" or similar
- command to save the document without formatting information.
- </p>
- </dd>
- <dt><a id="unicode-char" name="unicode-char">&ldquo;<code>`####' is not a valid character number</code>&rdquo;</a></dt>
- <dd>
- <p>
- You'll get several occurrences of this error if you use the Cougar
- DTD. Cougar uses the 16-bit UCS-4 (a.k.a. "Unicode") character set
- instead of the 8-bit ISO8859-1 character set used by HTML 2.0 and HTML
- 3.2. It also defines mnemonic entities for various Unicode characters;
- for instance, the entity <code>&amp;trade;</code> is defined as the
- character entity <code>&amp;#8482;</code>, which is the Unicode
- trademark character. Unfortunately, the <code>nsgmls</code> executable
- used by the validator does not appear to have 16-bit character support
- compiled in, and so it chokes on these 16-bit character entities.
- </p>
- <p>
- These errors are not produced by anything in your document and should
- not otherwise affect the validation of your document, so you can
- pretty much ignore them.
- </p>
- </dd>
- <dt><a id="bad-pub-id" name="bad-pub-id">&ldquo;<code>cannot generate system identifier for entity `HTML'</code>&rdquo;</a></dt>
- <dd>
- <p>
- Your <code>DOCTYPE</code> declaration contains a public identifier
- that the validator doesn't recognize. See the <a
- href="sgml.html#doctype">discussion of <code>DOCTYPE</code></a> for an
- explanation of what's happening, and what public identifiers the
- validator recognizes.
- </p>
- <p>
- Note that all of the rest of the errors you received are meaningless;
- the validator was unable to find a <a href="sgml.html#dtd">DTD</a> to
- work from, and thus could not validate your document.
- </p>
- </dd>
- <dt><a id="missing-subel" name="missing-subel">&ldquo;<code>missing a required sub-element of &lsquo;<var>FOO</var>&rsquo;</code>&rdquo;</a></dt>
- <dd>
- <p>
- The element &lsquo;<var>FOO</var>&rsquo; is defined to <em>require</em> one or more
- sub-elements. One example is TR which requires one or more TD or TH
- elements.
- </p>
- </dd>
- <dt><a id="start-tag" name="start-tag">&ldquo;<code>start tag was here</code>&rdquo;</a></dt>
- <dd>
- <p>
- Not an error, but rather a pointer to the start tag of the element
- the previous error referred to.
- </p>
- </dd>
- <dt><a id="utf8-bom" name="utf8-bom">&ldquo;<code>UTF-8 'BOM' detected and removed</code>&rdquo;</a></dt>
- <dd>
- <p>
- The document contained an UTF-8 encoded Unicode Byte Order Mark (BOM)
- as the first character and we have removed it before parsing.
- Many XML Processors fail to recognize it (although it's perfectly
- valid). To be on the safe side you may want to avoid using the
- BOM in UTF-8 encoded documents until browsers are updated to support it.
- </p>
- <p>
- Note that the BOM in <em>UTF-16</em> encoded documents
- is required and handled by all conforming XML Processors.
- </p>
- </dd>
- <dt><a id="text-not-allowed" name="text-not-allowed">&ldquo;<code> text is not allowed here; try wrapping the text in a more descriptive container</code>&rdquo;</a></dt>
- <dd>
- <p>
- The document contained bare text where an element was expected.
- For instance, you must wrap text in <code>&lt;p&gt;</code> if it
- appears directly inside the <code>&lt;body&gt;</code>.
- </p>
- <p>
- This error may also indicate an unquoted attribute value containing
- a reserved character (such as "<samp>/</samp>") which terminates the
- attribute. The net effect is that the rest of the attribute value
- appears to be plain text, outside any element, to an SGML parser.
- </p>
- </dd>
- <dt><a id="unkn-att-val" name="unkn-att-val">&ldquo;<code> value of attribute &lsquo;<var>FOO</var>&rsquo; cannot be &lsquo;<var>BAR</var>&rsquo;; must be one of &lsquo;<var>FOO</var>&rsquo;, &lsquo;<var>BAR</var>&rsquo;, &lsquo;<var>BAZ</var>&rsquo;</code>&rdquo;</a></dt>
- <dd>
- <p>
- An attribute was specified to contain one of a set of predefined
- values and you have used a value that is not in that set. The error
- message tells which attribute value was unknown and the possible
- legal values for this attribute.
- </p>
- </dd>
- <dt><a id="no-attr-end" name="no-attr-end">&ldquo;<code>character &lsquo;<var>FOO</var>&rsquo; not allowed in attribute specification list possibly caused by a missing quotation mark ending a previous attribute value</code>&rdquo;</a></dt>
- <dd>
- <p>
- A character that is illegal in the attribute list for a particular
- attribute was encountered. It's is likely that this is a result of
- a missing quote character on a previous attribute value.
- </p>
- </dd>
- <dt><a id="dup-attr" name="dup-attr">&ldquo;<code>duplicate specification of attribute &lsquo;<var>FOO</var>&rsquo;</code>&rdquo;</a></dt>
- <dd>
- <p>
- You have specified an attribute more than once. For instance, you've
- used the "height" attribute on the "img" element twice on the same
- "img" tag.
- </p>
- </dd>
- <dt><a id="invalid-attr-val" name="invalid-attr-val">&ldquo;<code>invalid attribute value</code>&rdquo;</a></dt>
- <dd>
- <p>
- The value of this attribute is not a legal value for attributes. For
- instance, the attribute cannot be the empty string. This is distinct
- from errors related to illegal values for a specific attribute.
- </p>
- </dd>
- <dt><a id="attr-spec-nmtoken" name="attr-spec-nmtoken">&ldquo;<code>an attribute specification must start with a name or name token</code>&rdquo;</a></dt>
- <dd>
- <p>
- An attribute name (and some attribute values) must start with one of
- a restricted set of characters. This error usually indicates that
- you have failed to add a closing quotation mark on a previous
- attribute value (so the attribute value looks like the start of a
- new attribute) or have used an attribute that is not defined
- (usually a typo in a common attribute name).
- </p>
- </dd>
- <dt><a id="inval-comment" name="inval-comment">&ldquo;<code>invalid comment declaration; check your comment syntax</code>&rdquo;</a></dt>
- <dd>
- <p>
- There is a syntax error in an SGML Comment Declaration. This may be
- caused by too many or too few hyphens "-" or that you have included
- an invalid character in the comment. The next message will be
- "comment declaration started here".
- </p>
- </dd>
- <dt><a id="assuming-missing-starttag" name="assuming-missing-starttag">&ldquo;<code>element &lsquo;<var>FOO</var>&rsquo; not allowed here; assuming missing &lsquo;<var>BAR</var>&rsquo; start-tag</code>&rdquo;</a></dt>
- <dd>
- <p>
- The referenced element &lsquo;<var>FOO</var>&rsquo; isn't allowed in the context it occurs
- in, but it would be if it was wrapped in a &lsquo;<var>BAR</var>&rsquo; element. The
- Validator has assumed that you have forgotten to add a &lsquo;<var>BAR</var>&rsquo;
- start tag and continued validation as if it was there. You should
- check if this is the case and insert the proper tag.
- </p>
- </dd>
-<!--
- <dt><a id="" name="">""</a></dt>
- <dd>
- <p>
- </p>
- </dd>
--->
+ <div id="toc">
+ <h2 id="TableOfContents">Table of Contents</h2>
+ <ul>
+ <li><a href="#undef-id">ID "<var>FOO</var>" already defined</a></li>
+ <li><a href="#unterm-comment-1">entity end not allowed in comment</a></li>
+ <li><a href="#unterm-comment-2">name start character invalid: only s and comment allowed in comment declaration</a></li>
+ <li><a href="#bad-comment">unknown declaration type "<var>FOO</var>"</a></li>
+ <li><a href="#attr-quoted">an attribute value must be a literal unless it contains only name characters</a></li>
+ <li><a href="#attr-char">character `X' not allowed in attribute specification list</a></li>
+ <li><a href="#name-length">length of attribute value must not exceed LITLEN less NORMSEP (1022)</a></li>
+ <li><a href="#undef-tag">element "<var>FOO</var>" undefined</a></li>
+ <li><a href="#not-allowed">document type does not allow element "<var>FOO</var>" here</a></li>
+ <li><a href="#not-contained">document type does not allow element "<var>FOO</var>" here; assuming missing "<var>BAR</var>" start-tag</a></li>
+ <li><a href="#attr-undef">there is no attribute "<var>FOO</var>" for this element (in this HTML version)</a></li>
+ <li><a href="#undef-attr-val">"<var>FOO</var>" is not a member of the group specified in the declared value of this attribute</a></li>
+ <li><a href="#bad-attr-char">syntax of attribute value does not conform to declared value</a></li>
+ <li><a href="#attr-bad-name">value of attribute "<var>FOO</var>" invalid: "#" cannot start a name</a></li>
+ <li><a href="#bad-abbrev-attr">"<var>FOO</var>" is not a member of a group specified for any attribute</a></li>
+ <li><a href="#attr-missing">required attribute "<var>FOO</var>" not specified</a></li>
+ <li><a href="#no-end-tag">end tag for "<var>FOO</var>" omitted, but its declaration does not permit this</a></li>
+ <li><a href="#floating-close">end tag for element "<var>FOO</var>" which is not open</a></li>
+ <li><a href="#omitted-content">end tag for "<var>FOO</var>" which is not finished</a></li>
+ <li><a href="#no-start-tag">start tag for "<var>FOO</var>" omitted, but its declaration does not permit this</a></li>
+ <li><a href="#bad-entity">unknown entity "<var>FOO</var>"</a></li>
+ <li><a href="#bad-char">non SGML character number ###</a></li>
+ <li><a href="#bad-pub-id">cannot generate system identifier for entity `HTML'</a></li>
+ <li><a href="#missing-subel">missing a required sub-element of "<var>FOO</var>"</a></li>
+ <li><a href="#start-tag">start tag was here</a></li>
+ <li><a href="#text-not-allowed"> text is not allowed here; try wrapping the text in a more descriptive container</a></li>
+ <li><a href="#unkn-att-val"> value of attribute "<var>FOO</var>" cannot be "<var>BAR</var>"; must be one of "<var>FOO</var>", "<var>BAR</var>", "<var>BAZ</var>"</a></li>
+ <li><a href="#no-attr-end">character "<var>FOO</var>" not allowed in attribute specification list possibly caused by a missing quotation mark ending a previous attribute value</a></li>
+ <li><a href="#dup-attr">duplicate specification of attribute "<var>FOO</var>"</a></li>
+ <li><a href="#invalid-attr-val">invalid attribute value</a></li>
+ <li><a href="#attr-spec-nmtoken">an attribute specification must start with a name or name token</a></li>
+ <li><a href="#inval-comment">invalid comment declaration; check your comment syntax</a></li>
+ <li><a href="#assuming-missing-starttag">element "<var>FOO</var>" not allowed here; assuming missing "<var>BAR</var>" start-tag</a></li>
+ </ul>
+ </div>
+
+ <div>
+ <h2>Listing of errors and their explanation</h2>
+ <dl>
+ <dt id="undef-id"><code>ID "<var>FOO</var>" already defined</code></dt>
+ <dd>
+ <p>
+ You have defined the id/name "<var>FOO</var>" more
+ then once. You will also get a message telling you where it was
+ first defined. Be aware that this message may be the result of an
+ ambiguity in the specification. While user-agents must treat
+ values of the id attribute as case-sensitive, they must still be
+ case-insensitive unique in the document. See
+ <a href="http://www.w3.org/TR/html4/struct/links.html#h-12.2.1">Section
+ 12.2.1 Syntax of anchor names</a> in the HTML 4.01 Recommendation
+ for further information.
+ </p>
+ </dd>
+ <dt id="unterm-comment-1"><code>entity end not allowed in comment</code></dt>
+ <dd>
+ <p>
+ Unterminated comment. The position indicator points to the very end of
+ the file, where the problem was detected; to find the beginning of the
+ comment, try searching for the last occurrence of
+ `<code>&lt;!--</code>' in the document.
+ </p>
+ </dd>
+ <dt id="unterm-comment-2"><code>name start character invalid: only s and comment allowed in comment declaration</code></dt>
+ <dd>
+ <p>
+ Unterminated comments again. This time, you have a case like:
+ </p>
+ <pre>
+ &lt;!-- This is the first unterminated comment &gt;
+ &lt;!-- This is the second one &gt;
+ </pre>
+ <p>
+ The validator (correctly) interprets the `<code>--</code>' in the
+ second comment as terminating the first comment, and then interprets
+ the text of the second comment as text between comments, which is not
+ allowed.
+ </p>
+ </dd>
+ <dt id="bad-comment"><code>unknown declaration type "<var>FOO</var>"</code></dt>
+ <dd>
+ <p>
+ Most likely an invalid comment of the form
+ <code>&lt;!invalid comment&gt;</code>; the validator is (correctly)
+ attempting to interpret it as an <a href="sgml.html#sgml">SGML</a>
+ markup declaration.
+ </p>
+ </dd>
+ <dt id="attr-quoted"><code>an attribute value must be a literal unless it contains only name characters</code></dt>
+ <dd>
+ <p>
+ You have an attribute whose value needs to be in quotes. If an
+ attribute value contains any character other than letters, digits,
+ hyphens and periods, it must be enclosed in double quotes (single
+ quotes would also be OK from an <a href="sgml.html#sgml">SGML</a>
+ standpoint, but some browsers don't recognize them).
+ </p>
+ </dd>
+ <dt id="attr-char"><code>character "X" not allowed in attribute specification list</code></dt>
+ <dd>
+ <p>
+ The validator has found a character inside an HTML tag that isn't
+ allowed there. This usually means you didn't put an attribute value in
+ quotes when necessary. It also probably means that the character in
+ question is not allowed in the value of the attribute at all, or you
+ would have received the <a href="#attr-quoted">previous error</a>
+ instead. See <a href="#bad-attr-char">below</a> for more information.
+ </p>
+ <p>
+ You can also get in trouble by forgetting the closing quote on an
+ attribute. For instance:
+ </p>
+ <pre>
+ &lt;IMG SRC="http://foo.com/fred.gif&gt;
+ &lt;IMG SRC="http://foo.com/joe.gif&gt;
+ </pre>
+ <p>
+ The validator will (correctly) interpret this as a SRC value of
+ <code>"http://foo.com/fred.gif&gt; &lt;IMG SRC="</code>, and then
+ choke on the following `:'. In this case, the position indicator in
+ the error message may be several lines below the line with the missing
+ quote.
+ </p>
+ </dd>
+ <dt id="name-length"><code>length of attribute value must not exceed LITLEN less NORMSEP (1022)</code></dt>
+ <dd>
+ <p>
+ This usually occurs in conjunction with the
+ <a href="#attr-char">previous error</a>. It almost always means that
+ you've forgotten a closing quote on an attribute value. For instance,
+ in:
+ </p>
+ <pre>
+ &lt;IMG SRC="fred.gif&gt;
+ &lt;!-- 50 lines of stuff --&gt;
+ &lt;IMG SRC="joe.gif"&gt;
+ </pre>
+ <p>
+ The SRC value for the first <code>&lt;IMG&gt;</code> is the entire
+ fifty lines of stuff up to the next double quote, which probably
+ exceeds the <a href="sgml.html#sgml">SGML</a>-defined length limit for
+ HTML string literals. Note that the position indicator in the error
+ message points to where the attribute value <em>ended</em> &mdash; in
+ this case, the <code>"joe.gif"</code> line.
+ </p>
+ </dd>
+ <dt id="undef-tag"><code>element "<var>FOO</var>" undefined</code></dt>
+ <dd>
+ <p>
+ You've used an unknown tag (represented here by "<var>FOO</var>"). Make sure the
+ DTD indicated by your DOCTYPE actually includes this element.
+ </p>
+ <p>
+ If the tag in question is a frame-related tag you must use the
+ "Frameset" DTD, and if you use (deprecated) physical markup ("FONT"
+ and friends) you must use the "Transitional" DTD.
+ </p>
+ </dd>
+ <dt id="not-allowed"><code>document type does not allow element "<var>FOO</var>" here</code></dt>
+ <dd>
+ <p>
+ Straightforward, but not terribly informative. There are a
+ <em>lot</em> of different errors that will generate this error
+ message:
+ </p>
+ <ul>
+ <li>
+ Using an unknown tag. In this case, the next error will be
+ <a href="#undef-tag">element "<var>FOO</var>" undefined"</a>.
+ </li>
+ <li>
+ Using a tag in the wrong place. For instance,
+ <code>&lt;TABLE&gt;&lt;TD&gt;blah&lt;/TABLE&gt;</code> will cause
+ this error. The trick here is that <code>&lt;TABLE&gt;</code> cannot
+ <em>directly</em> contain <code>&lt;TD&gt;</code>'s; it contains
+ <code>&lt;TR&gt;</code>'s which contain <code>&lt;TD&gt;</code>'s.
+ The above example should be
+ <code>&lt;TABLE&gt;&lt;TR&gt;&lt;TD&gt;blah&lt;/TABLE&gt;</code>.
+ </li>
+ </ul>
+ </dd>
+ <dt><a id="not-contained" name="not-contained">document type does not allow element "<var>FOO</var>" here; assuming missing "<var>BAR</var>" start-tag</a>"</dt>
+ <dd>
+ <p>
+ Similar to the <a href="#not-allowed">previous error</a>, but more
+ specific: in this case, you have a "<var>FOO</var>" element that is not contained
+ in a "<var>BAR</var>" element when "<var>FOO</var>" is not allowed outside of "<var>BAR</var>". Some of the
+ most common causes of this error are:
+ </p>
+ <ul>
+ <li>
+ Using the <code>DD</code> element as a fake paragraph indent.
+ <code>DD</code> is not allowed outside of a <code>DL</code> element.
+ </li>
+ <li>
+ Improper construction of a nested list. An inner UL or OL in a
+ nested list may not appear directly within an outer UL/OL, but only
+ within an LI of the outer UL/OL, as in the following example:
+ <pre>
+ &lt;OL&gt;
+ &lt;LI&gt;Obtain the following items:
+ &lt;UL&gt;
+ &lt;LI&gt;Ham&lt;/LI&gt;
+ &lt;LI&gt;Bread; one of:
+ &lt;UL&gt;
+ &lt;LI&gt;White&lt;/LI&gt;
+ &lt;LI&gt;Rye&lt;/LI&gt;
+ &lt;LI&gt;Whole wheat&lt;/LI&gt;
+ &lt;/UL&gt;
+ &lt;/LI&gt; &lt;!-- End of the "Bread" &lt;LI&gt; --&gt;
+ &lt;LI&gt;Cheese&lt;/LI&gt;
+ &lt;/UL&gt;
+ &lt;/LI&gt; &lt;!-- End of the "Obtain" &lt;LI&gt; --&gt;
+ &lt;LI&gt;Place ham and cheese between two slices of bread&lt;/LI&gt;
+ &lt;LI&gt;Consume the resulting ham-and-cheese sandwich&lt;/LI&gt;
+ &lt;/OL&gt;
+ </pre>
+ <p>
+ The <code>&lt;/LI&gt;</code> end tags are optional and are only
+ included above to emphasize how the structure of the nested list
+ is arranged; if you omit them, the parser will infer their
+ presence in the locations shown above.
+ </p>
+ </li>
+ </ul>
+ <p>
+ The validator has inserted a "<var>BAR</var>" start tag where it thinks there needs
+ to be one; it will probably complain later on that <a href="#no-end-tag">the
+ corresponding end tag is also missing</a>.
+ </p>
+ </dd>
+ <dt id="attr-undef"><code>there is no attribute "<var>FOO</var>" for this element (in this HTML version)</code></dt>
+ <dd>
+ <p>
+ You have used an attribute with an element that is defined not to have
+ that attribute. This is most commonly caused by using
+ vendor-specific attributes without setting the document type
+ appropriately.
+ </p>
+ </dd>
+ <dt id="undef-attr-val"><code>"<var>FOO</var>" is not a member of the group specified in the declared value of this attribute</code></dt>
+ <dd>
+ <p>
+ Similar to the <a href="#attr-undef">previous error</a>; this time,
+ you're using an attribute that is defined for the element, but with a
+ value that isn't defined for the attribute. For instance, the Netscape
+ extension <code>&lt;IMG ALIGN=ABSMIDDLE&gt;</code> will cause this
+ error; ABSMIDDLE isn't one of the allowed values for the ALIGN
+ attribute of <code>&lt;IMG&gt;</code> (unless, of course, you provided
+ a Netscape document type).
+ </p>
+ <p>
+ If you're using the Netscape document type, the BORDER attribute of
+ <code>&lt;TABLE&gt;</code> can cause this error.
+ </p>
+ <p>
+ This error can also be caused, oddly enough, by missing close quotes
+ on attribute values. For instance, given:
+ </p>
+ <pre>
+ &lt;IMG SRC="fred.gif&gt; &lt;IMG SRC="joe.gif&gt;
+ </pre>
+ <p>
+ The validator will (correctly) see a SRC attribute of
+ <code>"fred.gif&gt; &lt;IMG SRC="</code>, and then try to interpret
+ JOE.GIF as an attribute of <code>&lt;IMG&gt;</code>.
+ </p>
+ </dd>
+ <dt id="bad-attr-char"><code>syntax of attribute value does not conform to declared value</code></dt>
+ <dd>
+ <p>
+ Yet another attribute error; this time, the attribute in question was
+ defined to take a numeric value, or an <a
+ href="sgml.html#sgml">SGML</a> identifier value, and you used a
+ character that doesn't match what it was expecting.
+ </p>
+ <p>
+ One potentially annoying source of this error is the
+ <code>TD WIDTH</code> attribute. Whether intentionally or by oversight,
+ the HTML 3.2 DTD defines this attribute to have a value type of NUMBER,
+ which means that <code>&lt;TD WIDTH="50%"&gt;</code> is not allowed.
+ </p>
+ </dd>
+ <dt id="attr-bad-name"><code>value of attribute "<var>FOO</var>" invalid: "#" cannot start a name</code></dt>
+ <dd>
+ <p>
+ A special case of <a href="#bad-attr-char">the previous error</a>; the
+ attribute in question is defined to take as value an SGML name token,
+ which must begin with a letter.
+ </p>
+ </dd>
+ <dt id="bad-abbrev-attr"><code>"<var>FOO</var>" is not a member of a group specified for any attribute</code></dt>
+ <dd>
+ <p>
+ Another attribute error, this time referring to an "abbreviated"
+ attribute. <a href="sgml.html#sgml">SGML</a> allows you to omit the
+ name of an attribute if the attribute value is unambiguous. For
+ instance, <code>&lt;IMG ISMAP&gt;</code> is actually an abbreviation
+ of <code>&lt;IMG ISMAP=ISMAP&gt;</code>. (Technically, this also means
+ that e.g. <code>&lt;P ALIGN=CENTER&gt;</code> could be abbreviated to
+ <code>&lt;P CENTER&gt;</code>, but it is unlikely that current
+ browsers will get this right.) The validator has found something that
+ looks like an abbreviated attribute but doesn't match the value of any
+ attribute for this element. For instance, a typo like
+ <code>&lt;IMG ISNAP&gt;</code> would produce this error.
+ </p>
+ <p>
+ A missing close quote on a previous attribute value can also trigger
+ this error if the next quote it finds is followed by something that
+ looks like an abbreviated attribute; for instance,
+ <code>&lt;IMG SRC="fred.gif&gt;&lt;IMG SRC="joe.gif&gt;</code> would
+ produce this error, referring to the "attribute value" <code>JOE.GIF</code>.
+ </p>
+ </dd>
+ <dt id="attr-missing"><code>required attribute "<var>FOO</var>" not specified</code></dt>
+ <dd>
+ <p>
+ You left off a required attribute of the indicated element. The most
+ common such omitted attribute is the <code>ALT</code> attribute of the
+ <code>AREA</code> or <code>IMG</code> element; browsers will typically
+ use these to build a menu equivalent to your client-side image map if
+ the user has disabled image loading, so you'll want to use a
+ meaningful value here.
+ </p>
+ </dd>
+ <dt id="no-end-tag"><code>end tag for "<var>FOO</var>" omitted, but its declaration does not permit this</code></dt>
+ <dd>
+ <p>
+ You forgot to close something. "<var>FOO</var>" is the element you forgot to close
+ (and the next message, `start tag was here' points to the particular
+ instance of "<var>FOO</var>" in question); the positional indicator points to where
+ the validator expected you to close the element. There are a few
+ common ways that this can happen:
+ </p>
+ <ul>
+ <li>
+ You've put something inside the "<var>FOO</var>" element that isn't allowed
+ there. For instance,
+ <code>&lt;UL&gt;&lt;LI&gt;&lt;H4&gt;fake font change&lt;/H4&gt;&lt;/UL&gt;</code>
+ will cause this error, since headers aren't allowed inside <code>&lt;UL&gt;</code>'s; the
+ validator assumes that you meant to close the
+ <code>&lt;UL&gt;</code> before opening the <code>&lt;H4&gt;</code>.
+ </li>
+ <li>
+ Interlocked elements. For instance,
+ <code>&lt;B&gt;&lt;I&gt;nope&lt;/B&gt;&lt;/I&gt;</code> will cause
+ this error. HTML requires that you close elements inside-out
+ &mdash; that is, the last element you opened is the first element you should
+ close. In this example, you'd have to close the
+ <code>&lt;I&gt;</code> before the <code>&lt;B&gt;</code>.
+ </li>
+ <li>
+ Unclosed <code>&lt;A&gt;</code> tags. Yes, even
+ <code>&lt;A NAME="foo"&gt;</code> has to have a corresponding
+ <code>&lt;/A&gt;</code>. Note that an empty
+ <code>&lt;A NAME&gt;</code> element won't be recognized by some browsers; be
+ sure to put at least a word or two inside the
+ <code>&lt;A&gt;</code>.
+ </li>
+ <li>
+ Having unadorned text where the validator was expecting a
+ sub-element of "<var>FOO</var>". For instance,
+ <code>&lt;DL&gt;fake indent&lt;/DL&gt;</code> will produce this error,
+ since inside a
+ <code>&lt;DL&gt;</code>, the validator only expects to see
+ <code>&lt;DT&gt;</code>'s and <code>&lt;DD&gt;</code>'s.
+ </li>
+ <li>
+ A tag of the form <code>&lt;TABLE WIDTH=100%&gt;</code>. The
+ previous error should have been that the `%' was <a
+ href="#attr-char">"not allowed in attribute specification list"</a>.
+ What's happening here is that, in trying to get past the `%', the
+ validator has become confused and thinks the `%' is <em>inside</em>
+ the <code>&lt;TABLE&gt;...&lt;/TABLE&gt;</code>, thus triggering the
+ error message for the previous reason. This error will likely be
+ followed by mistaken complaints that your <code>&lt;TR&gt;</code>'s
+ are <a href="#not-allowed">"not allowed here"</a>, plus a complaint
+ about your <code>&lt;/TABLE&gt;</code> end tag. The solution is to
+ put the attribute value in quotes; ie. <code>&lt;TABLE
+ WIDTH="100%"&gt;</code>.
+ </li>
+ </ul>
+ <p>
+ In general, you should always explicitly close all elements and
+ quote all attribute values.
+ </p>
+ </dd>
+ <dt id="floating-close"><code>end tag for element "<var>FOO</var>" which is not open</code></dt>
+ <dd>
+ <p>
+ The validator found an end tag, represented here by "<var>FOO</var>", without a
+ corresponding start tag. This frequently occurs in conjunction with
+ the <a href="#no-end-tag">previous error</a>. For instance, given
+ <code>&lt;B&gt;&lt;I&gt;nope&lt;/B&gt;&lt;/I&gt;</code>, the validator
+ will insert a <code>&lt;/I&gt;</code> before the
+ <code>&lt;/B&gt;</code>, and then will find the
+ <code>&lt;/I&gt;</code> after the <code>&lt;/B&gt;</code> and will
+ have nothing to match it with.
+ </p>
+ <p>
+ A subtle variation of this is <code>&lt;P&gt;&lt;H4&gt;fake font
+ change&lt;/H4&gt;&lt;/P&gt;</code>. <code>&lt;H4&gt;</code>'s aren't
+ allowed inside <code>&lt;P&gt;</code>'s, but since HTML allows you to
+ omit the <code>&lt;/P&gt;</code> end tag for paragraphs, the validator
+ assumes that you meant <code>&lt;P&gt;&lt;/P&gt;&lt;H4&gt;fake font
+ change&lt;/H4&gt;&lt;/P&gt;</code>, in which case the final
+ <code>&lt;/P&gt;</code> is indeed superfluous.
+ </p>
+ <p>
+ This error can also be caused by incorrectly supplying an end tag for
+ "empty" elements like <code>&lt;HR&gt;</code>, <code>&lt;BR&gt;</code>
+ or <code>&lt;IMG&gt;</code>.
+ </p>
+ </dd>
+ <dt id="omitted-content"><code>end tag for "<var>FOO</var>" which is not finished</code></dt>
+ <dd>
+ <p>
+ You have a "<var>FOO</var>" element, but you have omitted some required sub-element
+ of it. For instance, a <code>TABLE</code> with no <code>TR</code>'s
+ would cause this error.
+ </p>
+ </dd>
+ <dt id="no-start-tag"><code>start tag for "<var>FOO</var>" omitted, but its declaration does not permit this</code></dt>
+ <dd>
+ <p>
+ The validator expected you to start a "<var>FOO</var>" element at the indicated
+ point. This probably means you've put unadorned text somewhere it
+ isn't allowed; for instance, <code>&lt;UL&gt;fake
+ indent&lt;/UL&gt;</code> will cause this error.
+ </p>
+ </dd>
+ <dt id="bad-entity"><code>unknown entity "<var>FOO</var>"</code></dt>
+ <dd>
+ <p>
+ The validator has found an entity (something like
+ <code>&amp;this;</code>) that it doesn't recognize. There are a few
+ possibilities:
+ </p>
+ <ul>
+ <li>
+ <p>
+ A reference to a URI that uses <code>&amp;</code> as a separator
+ between parameters, such as
+ "<code>http://example.org/prog?x=1&amp;y=2</code>".
+ </p>
+ <p>
+ To solve this problem, simply replace all the <code>&amp;</code>'s
+ in attribute values with <code>&amp;amp;</code> (user agents will
+ convert them back before following the links.)
+ </p>
+ <p>
+ Another way to get around this problem is for the author of the CGI
+ program to allow a different value to be used between arguments,
+ like ';' or '|', which would allow the link to be coded as e.g.
+ <code>&lt;a href="http://example.org/prog?x=1;y=2"&gt;</code>
+ </p>
+ </li>
+ <li>
+ An unterminated entity; for instance, <code>this&amp;ampthat</code>
+ for "this&amp;that", which the validator (correctly) interprets as a
+ request for the entity <code>&amp;ampthat;</code>. Technically, any
+ non-alphanumeric character (such as a space) will suffice to
+ terminate the entity, but some browsers get this wrong; the safest
+ thing to do is to terminate all entities with a semicolon, turning
+ our example into <code>this&amp;amp;that</code>.
+ </li>
+ <li>
+ The entity <code>&amp;quot;</code> in conjunction with the HTML 3.2
+ <code>DOCTYPE</code>. This entity was <a
+ href="http://lists.w3.org/Archives/Public/www-html/1997Mar/0003.html">accidentally
+ omitted</a> from the most recent version of the HTML 3.2 DTD. You
+ should be able to ignore this error safely, though if you wish, you
+ can replace <code>&amp;quot;</code> with the equivalent character
+ entity <code>&amp;#34;</code>.
+ </li>
+ </ul>
+ </dd>
+ <dt id="bad-char"><code>non SGML character number ###</code></dt>
+ <dd>
+ <p>
+ You've used an illegal character in your text. HTML uses the standard
+ ISO8859-1 character encoding, and ISO8859-1 leaves undefined 65
+ character codes (0 to 31 inclusive and 127 to 159 inclusive); the
+ validator has found one of these undefined characters in your
+ document. The character may appear on your browser as a curly quote,
+ or a trademark symbol, or some other fancy glyph; on a different
+ computer, however, it will likely appear as a completely different
+ character, or nothing at all.
+ </p>
+ <p>
+ Your best bet is to replace the character with the nearest equivalent
+ ASCII character, or to use an appropriate <a
+ href="http://www.w3.org/hypertext/WWW/MarkUp/html3/latin1.html">character
+ entity</a>. For more information on ISO8859-1, see <a
+ href="http://ppewww.ph.gla.ac.uk/%7Eflavell/aflavell.html">Alan
+ Flavell</a>'s excellent <a
+ href="http://ppewww.ph.gla.ac.uk/%7Eflavell/iso8859/">ISO8859-1/HTML
+ reference</a>.
+ </p>
+ <p>
+ This error can also be triggered by formatting characters embedded in
+ documents by some word processors. If you use a word processor to edit
+ your HTML documents, be sure to use the "Save as ASCII" or similar
+ command to save the document without formatting information.
+ </p>
+ </dd>
+ <dt id="bad-pub-id"><code>cannot generate system identifier for entity "HTML"</code></dt>
+ <dd>
+ <p>
+ Your <code>DOCTYPE</code> declaration contains a public identifier
+ that the validator doesn't recognize. See the <a
+ href="sgml.html#doctype">discussion of <code>DOCTYPE</code></a> for an
+ explanation of what's happening, and what public identifiers the
+ validator recognizes.
+ </p>
+ </dd>
+ <dt id="missing-subel"><code>missing a required sub-element of "<var>FOO</var>"</code></dt>
+ <dd>
+ <p>
+ The element "<var>FOO</var>" is defined to <em>require</em> one or more
+ sub-elements. One example is TR which requires one or more TD or TH
+ elements.
+ </p>
+ </dd>
+ <dt id="start-tag"><code>start tag was here</code></dt>
+ <dd>
+ <p>
+ Not an error, but rather a pointer to the start tag of the element
+ the previous error referred to.
+ </p>
+ </dd>
+ <dt id="text-not-allowed"><code> text is not allowed here; try wrapping the text in a more descriptive container</code></dt>
+ <dd>
+ <p>
+ The document contained bare text where an element was expected.
+ For instance, you must wrap text in <code>&lt;p&gt;</code> if it
+ appears directly inside the <code>&lt;body&gt;</code>.
+ </p>
+ <p>
+ This error may also indicate an unquoted attribute value containing
+ a reserved character (such as "<samp>/</samp>") which terminates the
+ attribute. The net effect is that the rest of the attribute value
+ appears to be plain text, outside any element, to an SGML parser.
+ </p>
+ </dd>
+ <dt id="unkn-att-val"><code> value of attribute "<var>FOO</var>" cannot be "<var>BAR</var>"; must be one of "<var>FOO</var>", "<var>BAR</var>", "<var>BAZ</var>"</code></dt>
+ <dd>
+ <p>
+ An attribute was specified to contain one of a set of predefined
+ values and you have used a value that is not in that set. The error
+ message tells which attribute value was unknown and the possible
+ legal values for this attribute.
+ </p>
+ </dd>
+ <dt id="no-attr-end"><code>character "<var>FOO</var>" not allowed in attribute specification list possibly caused by a missing quotation mark ending a previous attribute value</code></dt>
+ <dd>
+ <p>
+ A character that is illegal in the attribute list for a particular
+ attribute was encountered. It's is likely that this is a result of
+ a missing quote character on a previous attribute value.
+ </p>
+ </dd>
+ <dt id="dup-attr"><code>duplicate specification of attribute "<var>FOO</var>"</code></dt>
+ <dd>
+ <p>
+ You have specified an attribute more than once. For instance, you've
+ used the "height" attribute on the "img" element twice on the same
+ "img" tag.
+ </p>
+ </dd>
+ <dt id="invalid-attr-val"><code>invalid attribute value</code></dt>
+ <dd>
+ <p>
+ The value of this attribute is not a legal value for attributes. For
+ instance, the attribute cannot be the empty string. This is distinct
+ from errors related to illegal values for a specific attribute.
+ </p>
+ </dd>
+ <dt id="attr-spec-nmtoken"><code>an attribute specification must start with a name or name token</code></dt>
+ <dd>
+ <p>
+ An attribute name (and some attribute values) must start with one of
+ a restricted set of characters. This error usually indicates that
+ you have failed to add a closing quotation mark on a previous
+ attribute value (so the attribute value looks like the start of a
+ new attribute) or have used an attribute that is not defined
+ (usually a typo in a common attribute name).
+ </p>
+ </dd>
+ <dt id="inval-comment"><code>invalid comment declaration; check your comment syntax</code></dt>
+ <dd>
+ <p>
+ There is a syntax error in an SGML Comment Declaration. This may be
+ caused by too many or too few hyphens "-" or that you have included
+ an invalid character in the comment. The next message will be
+ "comment declaration started here".
+ </p>
+ </dd>
+ <dt id="assuming-missing-starttag"><code>element "<var>FOO</var>" not allowed here; assuming missing "<var>BAR</var>" start-tag</code></dt>
+ <dd>
+ <p>
+ The referenced element "<var>FOO</var>" isn't allowed in the context it occurs
+ in, but it would be if it was wrapped in a "<var>BAR</var>" element. The
+ Validator has assumed that you have forgotten to add a "<var>BAR</var>"
+ start tag and continued validation as if it was there. You should
+ check if this is the case and insert the proper tag.
+ </p>
+ </dd>
</dl>
-
<!--#include virtual="../footer.html" -->
</body>
</html>