/[pub]/test/html-webhacc/error-description-source.xml
Suika

Diff of /test/html-webhacc/error-description-source.xml

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.3 by wakaba, Mon Jul 16 10:55:11 2007 UTC revision 1.9 by wakaba, Mon Sep 3 14:30:46 2007 UTC
# Line 28  Web Document Conformance Checker (BETA)< Line 28  Web Document Conformance Checker (BETA)<
28    </d:desc>    </d:desc>
29  </d:item>  </d:item>
30    
31    <d:item name="after body"
32        class="parse-error">
33      <d:message xml:lang="en">Tag <code>&lt;<var>$0</var>&gt;</code>
34      is not allowed after the end tag <code>&lt;/body></code>.</d:message>
35      <d:desc xml:lang="en">
36        <p>The start or end tag of an element appears after the
37        <code>body</code> element has been closed.  The document is
38        non-conforming.</p>
39    
40        <p>Any content of the document other than <code>head</code>
41        contents and comments must be put into the <code>body</code>
42        element.</p>
43      </d:desc>
44    </d:item>
45    
46  <d:item name="bare ero"  <d:item name="bare ero"
47      class="tokenize-error">      class="tokenize-error">
48    <d:message xml:lang="en">The <code>&amp;</code> character must    <d:message xml:lang="en">The <code>&amp;</code> character must
# Line 38  Web Document Conformance Checker (BETA)< Line 53  Web Document Conformance Checker (BETA)<
53      is not part of any reference appears in the input stream.      is not part of any reference appears in the input stream.
54      The document is non-conforming.</p>      The document is non-conforming.</p>
55    
56        <p><strong>Any <code>&amp;</code> character in URI (or IRI)
57        must be escaped as <code>&amp;amp;</code>.</strong></p>
58    
59      <p>The <code>&amp;</code> character must      <p>The <code>&amp;</code> character must
60      be the first character of a reference:      be the first character of a reference:
61        <dl>        <dl>
# Line 63  Web Document Conformance Checker (BETA)< Line 81  Web Document Conformance Checker (BETA)<
81    </d:desc>    </d:desc>
82  </d:item>  </d:item>
83    
84    <d:item name="bare etago"
85        class="tokenize-error">
86      <d:message xml:lang="en">A <code>&lt;/</code> string is not followed
87      by a tag name.</d:message><!-- </ EOF -->
88      <d:desc xml:lang="en">
89        <p>There is a <code>&lt;</code> (<code>U+003C</code>
90        <code class="charname">LESS-THAN SIGN</code>) character
91        immediately followed by a <code>/</code> (<code>U+005F</code>
92        <code>SOLIDUS</code>) character, which is not part
93        of any end tag, in the input stream.  The document
94        is non-conforming.</p>
95    
96        <p>The <code>&lt;/</code> sequence immediately followed
97        by an <abbr title="End of file pseudo-character">EOF</abbr> is
98        interpreted as a string data of <code>&lt;/</code>.</p>
99    
100        <p>The <code>&lt;/</code> sequence as string data must
101        be escaped as:
102        <pre class="html example"><code>&amp;lt;/</code></pre>
103        </p>
104      </d:desc>
105    </d:item>
106    
107    <d:item name="bare stago"
108        class="tokenize-error">
109      <d:message xml:lang="en">A <code>&lt;</code> character is not followed
110      by tag name or by a <code>!</code> character.</d:message>
111      <d:desc xml:lang="en">
112        <p>A <code>&lt;</code> (<code>U+003C</code>
113        <code class="charname">LESS-THAN SIGN</code>) character which is not part
114        of any markup appears in the input stream.</p>
115    
116        <p>The <code>&lt;</code> character as a data character must
117        be escaped as:
118        <pre class="html example"><code>&amp;lt;</code></pre>
119        </p>
120      </d:desc>
121    </d:item>
122    
123  <d:item name="bare nero"  <d:item name="bare nero"
124      class="tokenize-error">      class="tokenize-error">
125    <d:message xml:lang="en">The decimal representation of the code position    <d:message xml:lang="en">The decimal representation of the code position
# Line 76  Web Document Conformance Checker (BETA)< Line 133  Web Document Conformance Checker (BETA)<
133      The document is non-conforming.</p>      The document is non-conforming.</p>
134    
135      <p>The string <code>&amp;#</code> must be the first two characters      <p>The string <code>&amp;#</code> must be the first two characters
     <code>NUMBER SIGN</code>) character must be the first two characters  
136      of a reference:      of a reference:
137        <dl>        <dl>
138        <dt>Numeric character reference</dt>        <dt>Numeric character reference</dt>
# Line 91  Web Document Conformance Checker (BETA)< Line 147  Web Document Conformance Checker (BETA)<
147      </p>      </p>
148    
149      <p>To represent <code>&amp;#</code> as data characters, use      <p>To represent <code>&amp;#</code> as data characters, use
150      named entity reference:      a named entity reference for the <code>&amp;</code> character:
151        <pre class="html example"><code>&amp;amp;#</code></pre>        <pre class="html example"><code>&amp;amp;#</code></pre>
152      </p>      </p>
153    </d:desc>    </d:desc>
# Line 113  Web Document Conformance Checker (BETA)< Line 169  Web Document Conformance Checker (BETA)<
169      of the code point of the character to be referenced.</p>      of the code point of the character to be referenced.</p>
170    
171      <p>To represent <code>&amp;#x</code> as data characters, use      <p>To represent <code>&amp;#x</code> as data characters, use
172      named entity reference:      a named entity reference for the <code>&amp;</code> character:
173        <pre class="html example"><code>&amp;amp;#x</code></pre>        <pre class="html example"><code>&amp;amp;#x</code></pre>
174      </p>      </p>
175    </d:desc>    </d:desc>
176  </d:item>  </d:item>
177    
178    <d:item name="bogus comment"
179        class="tokenize-error">
180      <d:message xml:lang="en">String <code>&lt;!</code> is not followed
181      by <code>--</code>.</d:message>
182      <d:desc xml:lang="en">
183        <p>There is a <code>&lt;</code> (<code>U+003C</code>
184        <code class="charname">LESS-THAN SIGN</code>) character
185        followed by a <code>!</code> (<code>U+0021</code>
186        <code class="charname">EXCLAMATION MARK</code>) character,
187        which is not followed by a <code>--</code> or
188        <code>!DOCTYPE</code>.  The document is non-conforming.</p>
189    
190        <dl class="switch">
191        <dt>Comments</dt>
192          <dd>In HTML documents, comments must be introduced by
193          <code>&lt;!--</code> (<code>&lt;!</code> <em>immediately</em> followed
194          by <em>two</em> <code>-</code>s) and must be terminated by
195          <code>--></code>.  Strings <code>&lt;!</code> not followed
196          by <code>--</code> and <code>&lt;!-</code> not followed by
197          <code>-</code> are not valid open delimiters for comments.</dd>
198        <dt>Marked sections, including <code>CDATA</code> sections</dt>
199          <dd>Marked sections are not allowed in HTML documents.</dd>
200        <dt>Markup declarations</dt>
201          <dd>Markup declarations, except <code>DOCTYPE</code>
202          and comment declarations, are not allowed in HTML documents.</dd>
203        <dt>String <code>&lt;!</code></dt>
204          <dd>String <code>&lt;!</code> must be escaped as
205          <code>&amp;lt;!</code>.</dd>
206        </dl>
207      </d:desc>
208    </d:item>
209    
210    <d:item name="bogus end tag"
211        class="tokenize-error">
212      <d:message xml:lang="en">String <code>&lt;/</code> is not followed
213      by tag name.</d:message><!-- </ non-name-start-char-non-EOF -->
214      <d:desc xml:lang="en">
215        <p>There is a <code>&lt;</code> (<code>U+003C</code>
216        <code class="charname">LESS-THAN SIGN</code>) character
217        immediately followed by a <code>/</code> (<code>U+005F</code>
218        <code>SOLIDUS</code>) character, which is not part
219        of any end tag, in the input stream.  The document
220        is non-conforming.</p>
221    
222        <p>The <code>&lt;/</code> sequence not followed by a
223        tag name is parsed as an opening of bogus comment.</p>
224    
225        <p>The <code>&lt;/</code> sequence as string data must
226        be escaped as:
227        <pre class="html example"><code>&amp;lt;/</code></pre>
228        </p>
229      </d:desc>
230    </d:item>
231    
232    <d:item name="dash in comment"
233        class="tokenize-error">
234      <d:message xml:lang="en">There is a <code>--</code> sequence
235      in a comment.</d:message>
236      <d:desc xml:lang="en">
237        <p>There is a <code>-</code> (<code>U+002D</code>
238        <code class="charname">HYPHEN-MINUS</code>) character
239        at the end of the comment or a <code>--</code> sequence
240        in the comment.  The document is non-conforming.</p>
241    
242        <p>Comments cannot contain a string <code>--</code>, as in XML.
243        Unlike SGML, there cannot be more than one comments
244        (where <i>comment</i> is an SGML term) in the comment
245        declaration.</p>
246      </d:desc>
247    </d:item>
248    
249  <d:item name="duplicate attribute"  <d:item name="duplicate attribute"
250      class="tokenize-error">      class="tokenize-error">
251    <d:message xml:lang="en">There are two attributes with same name.</d:message>    <d:message xml:lang="en">There are two attributes with name
252          <code><var>$0</var></code>.</d:message>
253    <d:desc xml:lang="en">    <d:desc xml:lang="en">
254      <p>There are more than one attributes with the same      <p>There are more than one attributes with the same
255      name in a tag.  The document is non-conforming.</p>      name in a tag.  The document is non-conforming.</p>
# Line 145  Web Document Conformance Checker (BETA)< Line 273  Web Document Conformance Checker (BETA)<
273      <code>embed</code>, <code>param</code>, <code>area</code>,      <code>embed</code>, <code>param</code>, <code>area</code>,
274      <code>col</code>, and <code>input</code> elements.</p>      <code>col</code>, and <code>input</code> elements.</p>
275    
276        <dl>
277        <dt><code>&lt;script/></code></dt>
278            <dd><p>The void element syntax cannot be used for <code>script</code>
279            element.  Even for an empty <code>script</code> element,
280            there must be an explicit end tag <code>&lt;/script></code>.</p>
281    
282            <p><strong>NOTE</strong>: Though some user agents interpret
283            void element syntax for <code>script</code> element as the
284            closing of the element, such usage is not allowed under
285            the current standard.</p></dd>
286        <dt><code>&lt;basefont/></code>, <code>&lt;bgsound/></code>,
287        <code>&lt;frame/></code>, <code>&lt;keygen/></code>,
288        <code>&lt;spacer/></code>, <code>&lt;wbr/></code></dt>
289            <dd>These elements are themselves non-conforming.</dd>
290        <!-- isindex, image -->
291        <dt><code>&lt;command/></code>, <code>&lt;event-source/></code>,
292        <code>&lt;source/></code></dt>
293            <dd>Future revision of HTML5 parsing algorithm is expected
294            to allow void element syntax for these elements.</dd>
295        <dt><code>&lt;a/></code>, <code>&lt;p/></code></dt>
296            <dd>These elements are not always empty and therefore
297            void element syntax is not allowed.</dd>
298        </dl>
299    
300      <p>Note that, unlike in XML, the void element syntax has      <p>Note that, unlike in XML, the void element syntax has
301      no effect in HTML.</p>      no effect in HTML.</p>
302    </d:desc>    </d:desc>
303  </d:item>  </d:item>
304    
305    
306    <d:item name="pio"
307        class="tokenize-error">
308      <d:message xml:lang="en">Processing instruction
309      (<code>&lt;?<var>...</var>></code>) cannot be used.</d:message>
310      <d:desc xml:lang="en">
311        <p>Processing instructions (<code>&lt;?<var>...</var>?></code>),
312        including XML declaration (<code>&lt;?xml <var>...</var>?></code>)
313        and XML style sheet <abbr title="processing instruction">PI</abbr>
314        (<code>&lt;?xml-stylesheet <var>...</var>?></code>), are not allowed
315        in the HTML syntax.  The document is non-conforming.</p>
316    
317        <dl>
318        <dt><code>&lt;?xml?&gt;</code> (XML declaration)</dt>
319            <dd>XML declaration is unnecessary for HTML documents.</dd>
320        <dt><code>&lt;?xml-stylesheet?></code> (XML style sheet
321        <abbr title="processing instruction">PI</abbr></dt>
322            <dd>Use HTML <code>link</code> element with <code>rel</code>
323            attribute set to <code>stylesheet</code> (or,
324            <code>alternate stylesheet</code> for an alternate style
325            sheet).</dd>
326        <dt><code>&lt;?php?&gt;</code> (PHP code)</dt>
327            <dd>The conformance checker does <em>not</em> support
328            checking for PHP source documents.</dd>
329        <dt>Other processing instructions</dt>
330            <dd>Processing instructions cannot be inserted in an HTML
331            document.  Use XML document or insert
332            <code>ProcessingInstruction</code> node by scripting.</dd>
333        </dl>
334    
335        <p>Web browsers will parse processing instructions as bogus
336        comments.  Some legacy Web browsers, such as IE:mac and
337        some mobile Web browsers, will display processing instructions
338        as string.</p>
339      </d:desc>
340    </d:item>
341    
342  </section>  </section>
343    
344  <section id="html5-parse-errors">  <section id="html5-parse-errors">
# Line 166  Web Document Conformance Checker (BETA)< Line 355  Web Document Conformance Checker (BETA)<
355    </d:desc>    </d:desc>
356  </d:item>  </d:item>
357    
358  <d:item name="in table"  <d:item name="DOCTYPE in the middle"
359        class="parse-error">
360      <d:message xml:lang="en">A <code>DOCTYPE</code> appears after any
361      element or data character has been seen.</d:message>
362      <d:desc xml:lang="en">
363        <p>A <code>DOCTYPE</code> appears after any element or data character
364        has been seen.  The document is non-conforming.</p>
365        
366        <p>The <code>DOCTYPE</code> must be placed before any
367        tag, reference, or data character.  Only white space characters
368        and comments can be inserted before the <code>DOCTYPE</code>.</p>
369      </d:desc>
370    </d:item>
371    
372    <d:item name="in a:a"
373        class="parse-error">
374      <d:message xml:lang="en">Anchor cannot be nested.</d:message>
375      <d:desc xml:lang="en">
376        <p>HTML <code>a</code> elements cannot be nested.
377        The document is non-conforming.</p>
378    
379        <p>In the HTML syntax, a start tag of the <code>a</code>
380        implies the end tag of any opening <code>a</code> element.</p>
381      </d:desc>
382    </d:item>
383    
384    <d:item name="in body"
385      class="parse-error">      class="parse-error">
386    <d:message xml:lang="en">Tag <code>&lt;<var>$0</var>&gt;</code>    <d:message xml:lang="en">Tag <code>&lt;<var>$0</var>&gt;</code>
387    is not allowed in <code>table</code>.</d:message>    is not allowed in the <code>body</code> element.</d:message>
388    <d:desc xml:lang="en">    <d:desc xml:lang="en">
389      <p>The start or end tag of an element appears in <code>table</code>.      <p>The start or end tag of an element, which
390        cannot be a descendant of <code>body</code> element, appears
391        in the input stream while the <code>body</code> element has been opened.
392      The document is non-conforming.</p>      The document is non-conforming.</p>
393      </d:desc>
394    </d:item>
395    
396    <d:item name="in head:head"
397        class="parse-error">
398      <d:message xml:lang="en">Start tag <code>&lt;head&gt;</code>
399      is not allowed in the <code>head</code> element.</d:message>
400      <d:desc xml:lang="en">
401        <p>There is a start tag <code>&lt;head></code> in the
402        <code>&lt;head></code> element.  The document is non-conforming.</p>
403    
404        <p>In an HTML document there must not be more than
405        one <code>head</code> element, therefore no more than one
406        start tag <code>&lt;head></code> can appear in the input stream.</p>
407      </d:desc>
408    </d:item>
409    
410    <d:item name="in table"
411        class="parse-error">
412      <d:message xml:lang="en">Tag <code>&lt;<var>$0</var>&gt;</code>
413      is not allowed in a <code>table</code> element.</d:message>
414      <d:desc xml:lang="en">
415        <p>The start or end tag of an element, which
416        cannot be a child of <code>table</code> element, appears
417        in the input stream while the <code>table</code> element has been opened
418        but no other element has been opened.  The document is non-conforming.</p>
419    
420      <p>In <code>table</code>, only table related elements      <p>In <code>table</code>, only table related elements
421      are allowed; any other element must be contained in      are allowed; any other element must be contained in
# Line 216  Web Document Conformance Checker (BETA)< Line 459  Web Document Conformance Checker (BETA)<
459    
460  <d:item name="no DOCTYPE"  <d:item name="no DOCTYPE"
461      class="parse-error">      class="parse-error">
462    <d:message xml:lang="en">This document does not start with the    <d:message xml:lang="en">This document does not start with a
463    <code>DOCTYPE</code>.</d:message>    <code>DOCTYPE</code>.</d:message>
464    <d:desc>    <d:desc>
465      <p>The document does not start with a <code>DOCTYPE</code>.      <p>The document does not start with a <code>DOCTYPE</code>.
# Line 242  Web Document Conformance Checker (BETA)< Line 485  Web Document Conformance Checker (BETA)<
485    </d:desc>    </d:desc>
486  </d:item>  </d:item>
487    
488    <d:item name="not first start tag"
489        class="parse-error">
490      <d:message xml:lang="en">This <code>&lt;html></code> tag is not
491      the first start tag.</d:message>
492      <d:desc>
493        <p>There is a start tag of the <code>html</code> element
494        that it not the first start tag in the input stream.
495        The document is non-conforming.</p>
496    
497        <p>In an HTML document, there cannot be more than one
498        <code>html</code> element and therefore there cannot be
499        more than one <code>&lt;html></code> tag.  In addition,
500        nothing can be placed before the <code>&lt;html></code> tag
501        except a <code>DOCTYPE</code>, white space characters,
502        and comments.</p>
503      </d:desc>
504    </d:item>
505    
506  <d:item name="not HTML5"  <d:item name="not HTML5"
507      class="parse-error">      class="parse-error">
508    <d:message xml:lang="en">This document is written in an old version of    <d:message xml:lang="en">This document is written in an old version of
509    HTML.</d:message>    HTML.</d:message>
510    <d:desc xml:lang="en">    <d:desc xml:lang="en">
511      <p>The document contains a <code>DOCTYPE</code> declaration      <p>The document contains a <code>DOCTYPE</code> declaration
512      that is different from HTML5 <code>DOCTYPE</code> (i.e. <code>&lt;!DOCTYPE      that is different from HTML5 <code>DOCTYPE</code> (i.e.
513      HTML&gt;</code>).  The document is non-conforming.</p>      <code>&lt;!DOCTYPE HTML&gt;</code>).  The document is non-conforming.</p>
514    
515      <p>The document might or might not be conformant to      <p>The document might or might not be conformant to
516      some version of HTML.  However, conformance to any HTML      some version of HTML.  However, conformance to any HTML
# Line 263  Web Document Conformance Checker (BETA)< Line 524  Web Document Conformance Checker (BETA)<
524      class="parse-error">      class="parse-error">
525    <d:message xml:lang="en">Element <code><var>$0</var></code> is not    <d:message xml:lang="en">Element <code><var>$0</var></code> is not
526    opened.</d:message>    opened.</d:message>
527      <d:desc>
528        <p>An end tag appears though no element with the same name
529        has been opened.  The document is non-conforming.</p>
530    
531        <p>For any end tag in HTML document, there must be a
532        corresponding start tag.</p>
533      </d:desc>
534  </d:item>  </d:item>
535    
536  </section>  </section>
# Line 279  Web Document Conformance Checker (BETA)< Line 547  Web Document Conformance Checker (BETA)<
547      context.  The document is non-conforming.</p>      context.  The document is non-conforming.</p>
548    
549      <p>Possible causes:      <p>Possible causes:
550        <dl>        <ul>
551        <dt>If the erred element is an inline-level element (such        <li><p>A data character cannot be a child
552        as <code>a</code> or <code>span</code>)</dt>        of certain sectioning elements such as <code>body</code>,
553            <dd><p>A data character cannot be a child        <code>section</code>, and <code>blockquote</code>.</p>
554            of certain sectioning elements such as <code>body</code>,  
555            <code>section</code>, and <code>blockquote</code>.</p>        <p>Any inline-level content must be put
556          in e.g. paragraph element such as <code>p</code>.</p></li>
557            <p>Any inline-level content must be put        <li><p>Though some elements such as <code>div</code>,
558            in e.g. paragraph element such as <code>p</code>.</p></dd>        <code>li</code>, and <code>td</code> allow
559        <dt>If the erred element is a block-level element (such as        <em>either one</em> of block-level or inline-level content
560        <code>div</code> or <code>h<var>n</var></code>)</dt>        is allowed.  If there is a block-level content,
561            <dd><p>Though some elements such as <code>div</code>,        any inline-level content must be put
562            <code>li</code>, and <code>td</code> allow        in e.g. paragraph element such as <code>p</code>.</p></li>
563            <em>either one</em> of block-level or inline-level content        </ul>
           is allowed.  If there is a block-level content,  
           any inline-level content must be put  
           in e.g. paragraph element such as <code>p</code>.</p></dd>  
       </dl>  
564      </p>      </p>
565    </d:desc>    </d:desc>
566  </d:item>  </d:item>
# Line 341  Web Document Conformance Checker (BETA)< Line 605  Web Document Conformance Checker (BETA)<
605      <p>An element appears where it is not allowed.  The document      <p>An element appears where it is not allowed.  The document
606      is non-conforming.</p>      is non-conforming.</p>
607    
     <p><strong>Note</strong>: The conformance checker does  
     <em>not</em> support form elements yet.</p>  
   
608      <p>Possible causes:      <p>Possible causes:
609        <dl>        <dl class="switch">
610        <dt>If the erred element is an inline-level element (such        <dt>If the element with the error is an inline-level element,
611        as <code>a</code> or <code>span</code>)</dt>        such as <code>a</code>, <code>progress</code>, or <code>img</code></dt>
612            <dd><p>An inline-level element cannot be a child            <dd><p>An inline-level element cannot be a child
613            of certain sectioning elements such as <code>body</code>,            of certain sectioning elements such as <code>body</code>,
614            <code>section</code>, and <code>blockquote</code>.</p>            <code>section</code>, and <code>blockquote</code>.</p>
615    
616            <p>Any inline-level content must be put            <p>Any inline-level content must be put
617            in e.g. paragraph element such as <code>p</code>.</p></dd>            in e.g. paragraph element such as <code>p</code>.</p></dd>
618        <dt>If the erred element is a block-level element (such as        <dt>If it is a block-level elements, such as <code>aside</code>,
619        <code>div</code> or <code>h<var>n</var></code>)</dt>        <code>div</code>, <code>h<var>n</var></code>,
620            <dd><p>Though some elements such as <code>div</code>,        <code>p</code>, or <code>section</code></dt>
621            <code>li</code>, and <code>td</code> allow            <dd><dl class="switch">
622            <em>either one</em> of block-level or inline-level content                <dt>If the parent element is <code>div</code>,
623            is allowed.  If there is a block-level content,                <code>li</code>, <code>td</code>, or <code>th</code></dt>
624            any inline-level content must be put                <!-- @@ TODO: more... -->
625            in e.g. paragraph element such as <code>p</code>.</p></dd>                    <!-- @@ TODO: <p><ul><li><p> -->
626        <dt>If the erred element is the root <code>html</code> element</dt>                    <dd><p>The parent element allows <em>either</em>
627                      block-level or inline-level content.  If there is a
628                      block-level content, any inline-level content must be
629                      put in e.g. paragraph element such as <code>p</code>.</p>
630                      <p>For example, an HTML document fragment
631                      <code class="bad example">&lt;div>&lt;p>Hello!&lt;/p> World!&lt;/div></code>
632                      is non-conforming, since a word <q>World!</q> does not belong
633                      to any paragraph.  (If not part of any paragraph, what is
634                      it!?)  A conforming example would be:
635                        <pre class="example"><code>&lt;div>&lt;p>Hello!&lt;/p> &lt;p>World!&lt;/p>&lt;/div></code></pre>
636                      </p></dd>
637                  <dt>If the parent element does <em>not</em> allow
638                  block-level elements as content</dt>
639                      <dd>The element is not allowed to be inserted here.
640                      For example, a <code>div</code> element cannot be
641                      a child of an <code>h1</code> element.</dd>
642              </dl></dd>
643          <dt>If the element with the error is a <code>noscript</code> element</dt>
644              <dd>The <code>noscript</code> element is allowed only in the context
645              where a block-level or inline-level content is expected
646              and in the <code>head</code> element.
647              It cannot be used in e.g. <code>ul</code>, <code>table</code>,
648              or <code>select</code>.</dd>
649          <dt>If the element with the error is the <code>html</code> element
650          that is the root element of an XHTML document</dt>
651            <dd><p>In an XHTML document, the root <code>html</code>            <dd><p>In an XHTML document, the root <code>html</code>
652            element must have an <code>xmlns</code> attribute            element must have an <code>xmlns</code> attribute
653            whose value is set to            whose value is set to
654            <code>http://www.w3.org/1999/xhtml</code>.</p></dd>            <code>http://www.w3.org/1999/xhtml</code>.</p></dd>
655          <dt>If the element with the error is <code>blink</code>,
656          <code>center</code>, or <code>marquee</code> element</dt>
657              <dd>These elements are not part of the HTML standard.
658              Use CSS for styling control.</dd>
659    
660          <dt><code>button</code>, <code>datalist</code>, <code>form</code>,
661          <code>input</code>, <code>label</code>,
662          <code>optgroup</code>, <code>option</code>, <code>output</code>,
663          <code>rb</code>, <code>rp</code>, <code>rt</code>, <code>ruby</code>,
664          <code>textarea</code>, or <code>textarea</code> element</dt>
665          <!-- rbc, rtc ? -->
666              <dd>These elements are intentionally not supported by the conformance
667              checker <em>yet</em>.</dd>
668        </dl>        </dl>
669      </p>      </p>
670    </d:desc>    </d:desc>
671  </d:item>  </d:item>
672    
673    <d:item name="ps element missing"
674        class="content-model-error">
675      <d:message xml:lang="en">There is no <code><var>$0</var></code>
676      element before this element.</d:message>
677      <d:desc xml:lang="en">
678        <p>There must be an element before another element, but there
679        is not.  The document is non-conforming.</p>
680    
681        <p>For example, there must be a <code>dt</code> element
682        before any <code>dd</code> element.</p>
683      </d:desc>
684    </d:item>
685    
686  </section>  </section>
687    
688  <section id="attribute-errors">  <section id="attribute-errors">
# Line 386  Web Document Conformance Checker (BETA)< Line 697  Web Document Conformance Checker (BETA)<
697      is non-conforming.</p>      is non-conforming.</p>
698    
699      <p>Some attribute is defined as <i>required</i>.      <p>Some attribute is defined as <i>required</i>.
     For example, any <code>img</code> element must have  
     <code>alt</code> and <code>src</code> attributes specified.  
700      Without required attributes specified, user agents      Without required attributes specified, user agents
701      cannot provide the full functionality of the element      cannot provide full functionality of the element to the user.</p>
702      to the user.</p>  
703        <dl class="switch">
704        <dt>HTML <code>img</code> element</dt>
705            <dd>The <code>src</code> attribute must be specified.
706            Additionally, the <code>alt</code> attribute must be specified
707            in many cases.</dd>
708        <dt>HTML <code>link</code> element</dt>
709            <dd>The <code>rel</code> attribute must be specified.
710            Note that the <code>rev</code> attribute is obsolete.</dd>
711        </dl>
712      </d:desc>
713    </d:item>
714    
715    <d:item name="attribute not allowed" class="attribute-error">
716      <d:message xml:lang="en">Attribute
717      <code><var>{local-name}</var></code> is not allowed for
718      <code><var>{element-local-name}</var></code> element.</d:message>
719      <d:desc xml:lang="en">
720        <p>An attribute is specified where it is not allowed.
721        The document is non-conforming.</p>
722    
723        <dl>
724        <dt>HTML <code>meta</code> element</dt>
725            <dd>For HTML <code>meta</code> element, <em>only one</em> of
726            <code>name</code>, <code>http-equiv</code>, or <code>charset</code>
727            attribute is allowed.</dd>
728        </dl>
729    </d:desc>    </d:desc>
730  </d:item>  </d:item>
731    
# Line 398  Web Document Conformance Checker (BETA)< Line 733  Web Document Conformance Checker (BETA)<
733      class="attribute-error">      class="attribute-error">
734    <d:message xml:lang="en">The <code>xml:lang</code> attribute is not    <d:message xml:lang="en">The <code>xml:lang</code> attribute is not
735    allowed in HTML document.</d:message>    allowed in HTML document.</d:message>
736    <d:desc>    <d:desc xml:lang="en">
737      <p>The <code>xml:lang</code> attribute is not allowed in      <p>The <code>xml:lang</code> attribute is not allowed in
738      HTML document.  The document is non-conforming.</p>      HTML document.  The document is non-conforming.</p>
739    
740      <p>The <code>xml:lang</code> attribute in <code>null</code>      <p>Use of the <code>xml:lang</code> attribute is conforming
741      namespace for HTML elements is defined as conforming only for      <em>only</em> in XML documents.</p>
     XML document.</p>  
742    
743      <p>To specify natural language information in HTML document,      <p>To specify natural language information in HTML document,
744      use <code>lang</code> attribute instead.</p>      use <code>lang</code> attribute instead.</p>
745    
746        <p>XHTML 1.0 Appendix C was encouraged to specify both
747        <code>lang</code> and <code>xml:lang</code> attributes with
748        the same value.  Such a duplication has <em>no effect</em> in practice.
749        Use only one of <code>lang</code> (in HTML) or <code>xml:lang</code> (in
750        XML).</p>
751    
752      <!-- @@ ISSUE: xml:lang in non-HTML element in DOM5 HTML created      <!-- @@ ISSUE: xml:lang in non-HTML element in DOM5 HTML created
753           from an HTML document? -->           from an HTML document? -->
754    </d:desc>    </d:desc>
# Line 438  Web Document Conformance Checker (BETA)< Line 779  Web Document Conformance Checker (BETA)<
779      XML document.  The document is non-conforming.</p>      XML document.  The document is non-conforming.</p>
780    
781      <p>The <code>lang</code> attribute in <code>null</code>      <p>The <code>lang</code> attribute in <code>null</code>
782      namespace for HTML elements is defined as conforming only for      namespace for HTML elements is conforming <em>only</em> in
783      HTML document.</p>      HTML documents.</p>
784    
785      <p>To specify natural language information in XML document,      <p>To specify natural language information in XML document,
786      use <code>xml:lang</code> attribute instead.</p>      use <code>xml:lang</code> attribute instead.</p>
# Line 455  Web Document Conformance Checker (BETA)< Line 796  Web Document Conformance Checker (BETA)<
796      <p>The <code>xmlns</code> attribute in the <code>null</code>      <p>The <code>xmlns</code> attribute in the <code>null</code>
797      namespace is not allowed in XHTML document.</p>      namespace is not allowed in XHTML document.</p>
798    
799      <p>This error should not occur in conformance-checking      <p>This error should not occur in conformance-checking of
800      static documents.</p>      static documents.</p>
801    </d:desc>    </d:desc>
802  </d:item>  </d:item>
# Line 468  Web Document Conformance Checker (BETA)< Line 809  Web Document Conformance Checker (BETA)<
809  <d:item name="enumerated:invalid"  <d:item name="enumerated:invalid"
810      class="attribute-value-error">      class="attribute-value-error">
811    <d:message xml:lang="en">This attribute only allow a limited set of    <d:message xml:lang="en">This attribute only allow a limited set of
812    values and the specified value is not one of them.</d:message>    values and the specified value <code><var>{@}</var></code> is not one
813      of them.</d:message>
814      <d:desc xml:lang="en">
815        <p>For this attribute only several values are allowed and the
816        value of the attribute is not one of them.  The document
817        is non-conforming.</p>
818    
819        <dl>
820        <dt>HTML <code>meta</code> element, <code>http-equiv</code> attribute</dt>
821            <dd><p>Only <code>Default-Style</code> and <code>Refresh</code>
822            is allowed.</p>
823            <p>Value <code>Content-Type</code> is obsolete; for charset
824            declaration, the <code>charset</code> attribute can be used as:
825            <pre class="html example"><code>&lt;meta charset="<var>charset-name</var>"></code></pre>
826            ... where <var>charset-name</var> is a name of the character encoding
827            of the document, such as <code>utf-8</code>.</p>
828            <p>Values <code>Content-Style-Type</code> and
829            <code>Content-Script-Type</code> are currently not allowed.</p>
830            <p>Value <code>Keywords</code> is not allowed.  Use
831            <code>name</code> attribute instead of <code>http-equiv</code>
832            attribute.</p>
833            <p>Values <code>Expires</code>, <code>Pragma</code>,
834            and <code>Cache-Control</code> are not allowed;
835            use <em>real</em> HTTP header fields for cache control.</p></dd>
836        </dl>
837      </d:desc>
838  </d:item>  </d:item>
839    
840  <d:item name="duplicate ID"  <d:item name="duplicate ID"
# Line 478  Web Document Conformance Checker (BETA)< Line 844  Web Document Conformance Checker (BETA)<
844    <!-- @@ <id=a xml:id=a>? -->    <!-- @@ <id=a xml:id=a>? -->
845  </d:item>  </d:item>
846    
847    <d:item name="link type:bad context"
848        class="attribute-value-error">
849      <d:message xml:lang="en">The link type <code><var>$0</var></code>
850      cannot be specified for this element.</d:message>
851      <d:desc xml:lang="en">
852        <p>The specified link type cannot be used for the element.
853        The document is non-conforming.</p>
854    
855        <p>Link types are associated with limited set of elements.
856        They cannot be used with other elements.</p>
857    
858        <p>For example, link type <code>bookmark</code>
859        can be used with <code>a</code> or <code>area</code> element,
860        while it cannot be used with <code>link</code> element.</p>
861      </d:desc>
862    </d:item>
863    
864    <d:item name="link type:non-conforming"
865        class="attribute-value-error">
866      <d:message xml:lang="en">The link type <code><var>$0</var></code>
867      is non-conforming.</d:message>
868      <d:desc xml:lang="en">
869        <p>The specified link type is non-conforming, and therefore
870        the document is non-conforming.</p>
871    
872        <dl>
873        <dt>Link type <code>contents</code></dt>
874          <dd>Use link type <code>index</code>.</dd>
875        <dt>Link type <code>copyright</code></dt>
876          <dd>Use link type <code>license</code>.</dd>
877        <dt>Link type <code>home</code></dt>
878          <dd>Use link type <code>index</code>.</dd>
879        <dt>Link type <code>start</code></dt>
880          <dd>Use link type <code>first</code>.</dd>
881        <dt>Link type <code>toc</code></dt>
882          <dd>Use link type <code>index</code>.</dd>
883        </dl>
884      </d:desc>
885    </d:item>
886    
887  <d:item name="reserved browsing context name"  <d:item name="reserved browsing context name"
888      class="attribute-value-error">      class="attribute-value-error">
889    <d:message xml:lang="en">This browsing context name is reserved.</d:message>    <d:message xml:lang="en">Browsing context name
890    <d:item>    <code><var>{@}</var></code> is reserved.</d:message>
891      <d:desc xml:lang="en">
892      <p>The specified browsing context name is reserved.      <p>The specified browsing context name is reserved.
893      The document is non-conforming.</p>      The document is non-conforming.</p>
894    
# Line 494  Web Document Conformance Checker (BETA)< Line 901  Web Document Conformance Checker (BETA)<
901      browsing context names <code>_blank</code>,      browsing context names <code>_blank</code>,
902      <code>_main</code>, and <code>_replace</code>.      <code>_main</code>, and <code>_replace</code>.
903      However, they are <em>not</em> conforming attribute values.</p>      However, they are <em>not</em> conforming attribute values.</p>
904    </d:item>    </d:desc>
905    </d:item>
906    
907    </section>
908    
909    <section id="attribute-value-warnings">
910    <h2>Attribute Value Warnings</h2>
911    
912    <d:item name="link type:proposed" level="s"
913        class="attribute-value-warning should">
914      <d:message xml:lang="en">Link type <code><var>$0</var></code>
915      is proposed but not accepted yet; it <em>should not</em> be
916      used until it has been accepted.</d:message>
917      <d:desc>
918        <p>The link type is in the <i>proposed</i> status; it
919        <em>should not</em> be used until it has been
920        accepted.</p>
921    
922        <p><strong>Warning</strong>: The data served to the
923        conforming checker might be out of date; it might have already
924        been accepted or rejected, depending on which the document
925        might be conforming or non-conforming.  See WHATWG Wiki
926        for the latest information.</p>
927      </d:desc>
928  </d:item>  </d:item>
929    
930  </section>  </section>
# Line 515  Web Document Conformance Checker (BETA)< Line 945  Web Document Conformance Checker (BETA)<
945    <code>th</code>) in the last row.</d:message>    <code>th</code>) in the last row.</d:message>
946  </d:item>  </d:item>
947    
948    <d:item name="table:rowspan extends table"
949        class="table-model-error">
950      <d:message xml:lang="en">This <code>rowspan</code> attribute
951      results in creating a table row that does not contain
952      any cell anchored to it.</d:message>
953      <d:desc xml:lang="en">
954        <p>The <code>rowspan</code> attribute value of the cell
955        is so specified that it extends a table in the row axis.
956        However, the extended row does not contain any cell by itself.
957        The document is non-conforming.</p>
958    
959        <p>For example, the table below is non-conforming:
960          <pre class="html non-conforming example"><code>&lt;table>
961    &lt;tbody>
962    &lt;tr>&lt;td rowspan=2>&lt;/td>&lt;/tr>
963    &lt;/tbody>
964    &lt;/table></code></pre>
965        ... since the second row contains only
966        a cell that spans between first and second rows.</p>
967      </d:desc>
968    </d:item>
969    
970  </section>  </section>
971    
972  <section id="imt-warnings">  <section id="imt-warnings">
# Line 522  Web Document Conformance Checker (BETA)< Line 974  Web Document Conformance Checker (BETA)<
974    
975  <d:item name="IMT:obsolete subtype"  <d:item name="IMT:obsolete subtype"
976      class="should" level="s">      class="should" level="s">
977    <d:message xml:lang="en">An <em>obsolete</em> subtype is used.</d:message>    <d:message xml:lang="en"><code><var>{@}</var></code>: An <em>obsolete</em>
978      subtype is used.</d:message>
979  </d:item>  </d:item>
980    
981  <d:item name="IMT:private subtype"  <d:item name="IMT:private subtype"
982      class="should" level="s">      class="should" level="s">
983    <d:message xml:lang="en">A private (<code>x-</code> or <code>x.</code>)    <d:message xml:lang="en"><code><var>{@}</var></code>: A private
984    subtype is used.</d:message>    (<code>x-</code> or <code>x.</code>) subtype is used.</d:message>
985  </d:item>  </d:item>
986    
987  <d:item name="IMT:unregistered subtype"  <d:item name="IMT:unregistered subtype"
988      class="should" level="s">      class="should" level="s">
989    <d:message xml:lang="en">The subtype is not registered to IANA.</d:message>    <d:message xml:lang="en"><code><var>{@}</var></code>: The subtype is
990      not registered to IANA.</d:message>
991  <!-- TODO: Unknown message?? -->  <!-- TODO: Unknown message?? -->
992  </d:item>  </d:item>
993    
# Line 544  Web Document Conformance Checker (BETA)< Line 998  Web Document Conformance Checker (BETA)<
998    
999  <d:item name="URI::syntax error"  <d:item name="URI::syntax error"
1000      class="must" level="m">      class="must" level="m">
1001    <d:message xml:lang="en">This string is not an IRI syntactically.</d:message>    <d:message xml:lang="en">The specified value is syntactically not an IRI
1002      reference.</d:message>
1003      <d:desc xml:lang="en">
1004        <p>The specified value does not satisfy the syntactical requirements
1005        for IRI references.  The document is non-conforming.</p>
1006    
1007        <p>Possible causes:
1008          <ul>
1009          <li>The string might contain one or more white space characters.
1010          Especially, the <code> </code> (<code>U+0020</code>
1011          <code class="charname">SPACE</code>) character cannot be
1012          used in IRI references.</li>
1013          </ul>
1014        </p>
1015      </d:desc>
1016  </d:item>  </d:item>
1017    
1018  </section>  </section>
1019    
1020  <section id="uri-warnings">  <section id="uri-shoulds">
1021  <h2>URI (or IRI) Warnings</h2>  <h2>URI (or IRI) Should-level Errors</h2>
1022    
1023  <d:item name="URI::dot-segment"  <d:item name="URI::dot-segment"
1024      class="should" level="s">      class="should" level="s">
1025    <d:message xml:lang="en">Dot-segment (<code>.</code> or    <d:message xml:lang="en">A dot-segment (<code>.</code> or
1026    <code>..</code>) should not occur in an absolute reference.</d:message>    <code>..</code>) occurs in an absolute reference.</d:message>
1027    <d:desc>    <d:desc>
1028      <p>Dot-segment (<code>.</code> or <code>..</code>) should      <p>Dot-segment (<code>.</code> or <code>..</code>) should
1029      not occur in an absolute reference.</p>      not occur in an absolute reference.</p>
# Line 570  Web Document Conformance Checker (BETA)< Line 1038  Web Document Conformance Checker (BETA)<
1038    
1039  <d:item name="URI::empty path"  <d:item name="URI::empty path"
1040      class="should" level="s">      class="should" level="s">
1041    <d:message xml:lang="en">This IRI should explicitly end with    <d:message xml:lang="en">This IRI does not end with
1042    <code>/</code>.</d:message>    a <code>/</code>.</d:message>
1043    </d:item>
1044    
1045    <d:item name="URI::lowercase hexadecimal digit"
1046        class="should" level="s">
1047      <d:message xml:lang="en">A lowercase hexadecimal digit is used
1048      in percent-encoding.</d:message>
1049      <d:desc xml:lang="en">
1050        <p>The hexadecimal digit in percent-encoding string in the IRI
1051        is in lowercase.  Though the IRI <em>is</em> conforming,
1052        it should be in uppercase.</p>
1053      </d:desc>
1054    </d:item>
1055    
1056    <d:item name="URI::percent-encoded unreserved"
1057        class="should" level="s">
1058      <d:message xml:lang="en">An unreserved character is
1059      percent-encoded.</d:message>
1060      <d:desc xml:lang="en">
1061        <p>An unreserved character is percent-encoded in the IRI.
1062        Though it <em>is</em> conforming, it should be in the
1063        decoded (or bare) form.</p>
1064      </d:desc>
1065    </d:item>
1066    
1067    <d:item name="URI::uppercase scheme name"
1068        class="should" level="s">
1069      <d:message xml:lang="en">URI scheme name is in uppercase.</d:message>
1070      <d:desc xml:lang="en">
1071        <p>The scheme part of the IRI is written in uppercase letter.</p>
1072    
1073        <p>Uppercase scheme names are not required to be processed
1074        correctly.</p>
1075    <!-- @@
1076     RFC 3986 3.1.
1077     > Although schemes are case-
1078       insensitive, the canonical form is lowercase and documents that
1079       specify schemes must do so with lowercase letters.
1080    
1081     > An implementation ... should only produce lowercase scheme names for
1082       consistency.
1083    -->
1084      </d:desc>
1085  </d:item>  </d:item>
1086    
1087  </section>  </section>
# Line 579  Web Document Conformance Checker (BETA)< Line 1089  Web Document Conformance Checker (BETA)<
1089  <section id="unsupported-messages">  <section id="unsupported-messages">
1090  <h2><i>Unsupported</i> Messages</h2>  <h2><i>Unsupported</i> Messages</h2>
1091    
1092  <d:item name="attribute"  <d:item name="element"
1093      class="unsupported" level="unsupported">      class="unsupported" level="unsupported">
1094    <d:message xml:lang="en">This attribute is not supported by the    <d:message xml:lang="en">Conformance checking for element
1095    conformance checker; <em>it might or might not be conforming</em>.</d:message>    <code><var>{local-name}</var></code> is not supported; <em>it might or
1096      might not be conforming</em>.</d:message>
1097    <d:desc xml:lang="en">    <d:desc xml:lang="en">
1098      <p>The conformant checker does not support the attribute.      <p>The conformant checker does not support the element.
1099      It cannot determine whether the document is conforming or not.</p>      It cannot determine whether the document is conforming or not.</p>
1100    </d:desc>    </d:desc>
1101  </d:item>  </d:item>
1102    
1103  <d:item name="element"  <d:item name="attribute"
1104      class="unsupported" level="unsupported">      class="unsupported" level="unsupported">
1105    <d:message xml:lang="en">This element is not supported by the    <d:message xml:lang="en">Conformance checking for attribute
1106    conformance checker; <em>it might or might not be conforming</em>.</d:message>    <code><var>{local-name}</var></code> of element
1107      <code><var>{element-local-name}</var></code> is not supported;
1108      <em>it might or might not be conforming</em>.</d:message>
1109    <d:desc xml:lang="en">    <d:desc xml:lang="en">
1110      <p>The conformant checker does not support the element.      <p>The conformant checker does not support the attribute.
1111      It cannot determine whether the document is conforming or not.</p>      It cannot determine whether the document is conforming or not.</p>
1112    </d:desc>    </d:desc>
1113  </d:item>  </d:item>
1114    
1115  <d:item name="link type"  <d:item name="link type"
1116      class="unsupported" level="unsupported">      class="unsupported" level="unsupported">
1117    <d:message xml:lang="en">The link type <code>$0</code> is not standardized    <d:message xml:lang="en">Link type <code><var>$0</var></code> is not
1118    or registered at the time of the release of the conformance checker;    standardized or registered at the time of the release of the conformance
1119    <em>it is non-conforming unless it has now been registered</em>.</d:message>    checker; <em>it is non-conforming unless it now has been
1120      registered</em>.</d:message>
1121    <d:desc xml:lang="en">    <d:desc xml:lang="en">
1122      <p>The <code>rel</code> attribute is defined as a list of link types.      <p>The <code>rel</code> attribute is defined as a list of link types.
1123      Some common link types are defined in the HTML5 specification.      Some common link types are defined in the HTML5 specification.
# Line 615  Web Document Conformance Checker (BETA)< Line 1129  Web Document Conformance Checker (BETA)<
1129      The link type might have been added to the registry since then.      The link type might have been added to the registry since then.
1130      In such case it might be conforming.  Otherwise, the      In such case it might be conforming.  Otherwise, the
1131      document is non-conforming.</p>      document is non-conforming.</p>
1132    
1133        <dl>
1134        <dt>Link types <code>shortcut icon</code></dt>
1135            <dd>Link type <code>shortcut</code> is not registered.
1136            Use only <code>icon</code> for linking to so-called favicon.</dd>
1137        </dl>
1138    </d:desc>    </d:desc>
1139  </d:item>  </d:item>
1140    
1141    <d:item name="event handler"
1142        class="unsupported" level="unsupported">
1143      <d:message xml:lang="en">Conformance checking for event handler attribute
1144      is not supported; <em>it might or might not be conforming.</em></d:message>
1145    </d:item>
1146    
1147    <d:item name="language tag"
1148        class="unsupported" level="unsupported">
1149      <d:message xml:lang="en">Conformance checking for language tag
1150      is not supported; <em>it might or might not be conforming.</em></d:message>
1151    </d:item>
1152    
1153    <d:item name="media query"
1154        class="unsupported" level="unsupported">
1155      <d:message xml:lang="en">Conformance checking for media query
1156      is not supported; <em>it might or might not be conforming.</em></d:message>
1157    </d:item>
1158    
1159    <d:item name="script"
1160        class="unsupported" level="unsupported">
1161      <d:message xml:lang="en">Conformance checking for script
1162      language <code><var>$0</var></code> is not supported;
1163      <em>it might or might not be conforming.</em></d:message>
1164    </d:item>
1165    
1166    <d:item name="style"
1167        class="unsupported" level="unsupported">
1168      <d:message xml:lang="en">Conformance checking for style
1169      language <code><var>$0</var></code> is not supported;
1170      <em>it might or might not be conforming.</em></d:message>
1171    </d:item>
1172    
1173  </section>  </section>
1174    
1175  <d:catalog>  <d:catalog>
# Line 632  manakaiIsHTML:0;;XML Document Line 1184  manakaiIsHTML:0;;XML Document
1184  <section id="license">  <section id="license">
1185  <h2>License of This Document</h2>  <h2>License of This Document</h2>
1186    
1187  <p>Copyright 2007 <a href="http://suika.fam.cx/~wakaba/who?">Wakaba</a></p>  <p>Copyright 2007 <a href="http://suika.fam.cx/~wakaba/who?" rel="author" xml:lang="ja">Wakaba</a></p>
1188  <p>This library is free software; you can redistribute it  <p>This document is free software; you can redistribute it
1189  and/or modify it under the same terms as Perl itself.</p>  and/or modify it under the same terms as Perl itself.</p>
1190  </section>  </section>
1191    

Legend:
Removed from v.1.3  
changed lines
  Added in v.1.9

[email protected]
ViewVC Help
Powered by ViewVC 1.1.24