Skip to content

Commit

Permalink
++ ChangeLog 17 Jul 2007 13:52:41 -0000
Browse files Browse the repository at this point in the history
2007-07-17  Wakaba  <wakaba@suika.fam.cx>

	* alert.png, error.png, info.png: New images.

	* LICENSE: New image file names are added.

	* cc-interface.en.html: Link to the style sheet is added.

	* cc-style.css: Duplicate identifiers and terms
	are decorated by icon.

	* cc.cgi: |h1| links to the interface page.
	(#identifiers): New section.

	* error-description-source.en.xml: More error types are
	added.
  • Loading branch information
Wakaba committed Jul 17, 2007
1 parent 5da723f commit 2331474
Show file tree
Hide file tree
Showing 11 changed files with 158 additions and 16 deletions.
17 changes: 17 additions & 0 deletions ChangeLog
@@ -1,3 +1,20 @@
2007-07-17 Wakaba <wakaba@suika.fam.cx>

* alert.png, error.png, info.png: New images.

* LICENSE: New image file names are added.

* cc-interface.en.html: Link to the style sheet is added.

* cc-style.css: Duplicate identifiers and terms
are decorated by icon.

* cc.cgi: |h1| links to the interface page.
(#identifiers): New section.

* error-description-source.en.xml: More error types are
added.

2007-07-16 Wakaba <wakaba@suika.fam.cx>

* cc.cgi: Set |STDOUT| encoding as |utf8|.
Expand Down
3 changes: 2 additions & 1 deletion LICENSE
@@ -1,6 +1,7 @@
See each file for license.

large-alert.png, large-info.png, large-stop.png:
large-alert.png, large-info.png, large-stop.png,
alert.png, info.png, error.png:
GPL. See
<http://www.lullabot.com/articles/free_gpl_icons_lullacons_pack_1>
for the full package. See
Expand Down
Binary file added alert.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions cc-interface.en.html
Expand Up @@ -2,6 +2,7 @@
<html lang="en">
<head>
<title>Web Document Conformance Checker (BETA)</title>
<link rel="stylesheet" href="cc-style.css" type="text/css">
<style>
input[type=text], input[type=url] {
width: 33em;
Expand Down
6 changes: 4 additions & 2 deletions cc-msg.en.txt
Expand Up @@ -6,8 +6,10 @@ bare hcro;tokenize-error;The hexadecimal representation of the code position of
dash in comment;tokenize-error;There is a <code>--</code> sequence in a comment.
duplicate attribute;tokenize-error;There are two attributes with same name.
nestc;tokenize-error;Void element syntax (<code>/&gt;</code>) cannot be used for this element.
pio;tokenize-error;Processing instruction (<code>&lt;?<var>...</var>?&gt;</code>) cannot be used.
after head;parse-error;The <code><var>$0</var></code> element cannot be inserted between <code>head</code> and <code>body</code> elements.
DOCTYPE in the middle;parse-error;A <code>DOCTYPE</code> appears after any element or data character has been seen.
in a:a;parse-error;Anchor cannot be nested.
in body;parse-error;Tag <code>&lt;<var>$0</var>&gt;</code> is not allowed in <code>body</code>.
in table;parse-error;Tag <code>&lt;<var>$0</var>&gt;</code> is not allowed in <code>table</code>.
in table:#character;parse-error;Data character is not allowed in <code>table</code>.
Expand All @@ -27,7 +29,7 @@ in XML:lang;attribute-error;The <code>lang</code> attribute is not allowed in XM
in XML:xmlns;attribute-error;The <code>xmlns</code> attribute in the <code>null</code> namespace is not allowed in XHTML document. The document is non-conforming.
enumerated:invalid;attribute-value-error;This attribute only allow a limited set of values and the specified value is not one of them.
duplicate ID;attribute-value-error;This identifier has already been assigned to another element.
link type:bad-context;attribute-value-error;The link type <code><var>$0</var></code> cannot be specified for this element.
link type:bad context;attribute-value-error;The link type <code><var>$0</var></code> cannot be specified for this element.
link type:non-conforming;attribute-value-error;The link type <code><var>$0</var></code> is non-conforming.
reserved browsing context name;attribute-value-error;This browsing context name is reserved.
s:link type:proposed;attribute-value-warning should;Link type <code><var>$0</var></code> is proposed but not accepted yet; it <em>should not</em> be used until it has been accepted.
Expand All @@ -36,7 +38,7 @@ table:no cell in last row;table-model-error;The table has no cell (<code>td</cod
s:IMT:obsolete subtype;should;An <em>obsolete</em> subtype is used.
s:IMT:private subtype;should;A private (<code>x-</code> or <code>x.</code>) subtype is used.
s:IMT:unregistered subtype;should;The subtype is not registered to IANA.
m:URI::syntax error;must;This string is not an IRI syntactically.
m:URI::syntax error;must;This string is syntactically not an IRI.
s:URI::dot-segment;should;Dot-segment (<code>.</code> or <code>..</code>) should not occur in an absolute reference.
s:URI::empty path;should;This IRI should explicitly end with <code>/</code>.
s:URI::lowercase hexadecimal digit;should;Hexadecimal digit in percent-encoding should be in lowercase.
Expand Down
16 changes: 14 additions & 2 deletions cc-style.css
Expand Up @@ -108,7 +108,19 @@ q:before, q:after {
padding-left: 40px;
min-height: 32px;
background-image: url(large-stop);
background-position: top left;
background-position: center left;
background-repeat: no-repeat;
}

#identifiers dd, #terms dd {
margin-left: 20px;
padding-left: 20px;
min-height: 20px;
}

#identifiers dd + dd, #terms dd + dd {
background-image: url(error);
background-position: center left;
background-repeat: no-repeat;
}

Expand Down Expand Up @@ -179,6 +191,6 @@ Copyright 2007 Wakaba <w@suika.fam.cx>
This library is free software; you can redistribute it
and/or modify it under the same terms as Perl itself.
$Date: 2007/07/01 10:02:24 $
$Date: 2007/07/17 13:52:54 $
*/
25 changes: 22 additions & 3 deletions cc.cgi
Expand Up @@ -50,7 +50,8 @@ my $http = SuikaWiki::Input::HTTP->new;
<link rel="stylesheet" href="../cc-style.css" type="text/css">
</head>
<body>
<h1>Web Document Conformance Checker (<em>beta</em>)</h1>
<h1><a href="../cc-interface">Web Document Conformance Checker</a>
(<em>beta</em>)</h1>
<div id="document-info" class="section">
<dl>
Expand Down Expand Up @@ -227,7 +228,9 @@ if (defined $input->{s}) {
$i++;
print STDOUT qq[<div class="section" id="table-$i"><h3>] .
get_node_link ($table_el) . q[</h3>];


## TODO: Make |ContentChecker| return |form_table| result
## so that this script don't have to run the algorithm twice.
my $table = Whatpm::HTMLTable->form_table ($table_el);

for (@{$table->{column_group}}, @{$table->{column}}, $table->{caption}) {
Expand Down Expand Up @@ -262,6 +265,22 @@ if (defined $input->{s}) {
print STDOUT qq[</div>];
}

if (keys %{$elements->{id}}) {
print STDOUT qq[
<div id="identifiers" class="section">
<h2>Identifiers</h2>
<dl>
];
for my $id (sort {$a cmp $b} keys %{$elements->{id}}) {
print STDOUT qq[<dt>@{[htescape $id]}</dt>];
for (@{$elements->{id}->{$id}}) {
print STDOUT qq[<dd>].get_node_link ($_).qq[</dd>];
}
}
print STDOUT qq[</dl></div>];
}

if (keys %{$elements->{term}}) {
print STDOUT qq[
<div id="terms" class="section">
Expand Down Expand Up @@ -673,4 +692,4 @@ and/or modify it under the same terms as Perl itself.
=cut

## $Date: 2007/07/16 13:56:26 $
## $Date: 2007/07/17 13:52:54 $
66 changes: 61 additions & 5 deletions error-description-source.xml
Expand Up @@ -183,6 +183,36 @@ Web Document Conformance Checker (BETA)</title>
</d:desc>
</d:item>


<d:item name="pio"
class="tokenize-error">
<d:message xml:lang="en">Processing instruction
(<code>&lt;?<var>...</var>?></code>) cannot be used.</d:message>
<d:desc xml:lang="en">
<p>Processing instructions (<code>&lt;?<var>...</var>?></code>),
including XML declaration (<code>&lt;?xml <var>...</var>?></code>)
and XML style sheet <abbr title="processing instruction">PI</abbr>
(<code>&lt;xml-stylesheet <var>...</var>?></code>), are not allowed
in the HTML syntax. The document is non-conforming.</p>

<p>If it is necessary to embed a processing instruction
in the HTML document, you must use the XML syntax instead.</p>

<p>In the HTML syntax, XML declaration is not necessary.</p>

<p>Instead of XML style sheet,
<abbr title="processing instruction">PI</abbr>s, you must
use the HTML <code>link</code> element whose <code>rel</code>
attribute is set to <code>stylesheet</code> (or <code>alternate
stylesheet</code> for an aleternate style sheet).</p>

<p>Web browsers will parse processing instructions as bogus
comments. Some legacy Web browsers, such as IE:mac and
some mobile browsers, will display processing instructions
as string.</p>
</d:desc>
</d:item>

</section>

<section id="html5-parse-errors">
Expand Down Expand Up @@ -213,10 +243,22 @@ Web Document Conformance Checker (BETA)</title>
</d:desc>
</d:item>

<d:item name="in a:a"
class="parse-error">
<d:message xml:lang="en">Anchor cannot be nested.</d:message>
<d:desc xml:lang="en">
<p>HTML <code>a</code> elements cannot be nested.
The document is non-conforming.</p>

<p>In the HTML syntax, a start tag of the <code>a</code>
implies the end tag of any opening <code>a</code> element.</p>
</d:desc>
</d:item>

<d:item name="in body"
class="parse-error">
<d:message xml:lang="en">Tag <code>&lt;<var>$0</var>&gt;</code>
is not allowed in <code>body</code>.</d:message>
is not allowed in a <code>body</code> element.</d:message>
<d:desc xml:lang="en">
<p>The start or end tag of an element, which
cannot be a descendant of <code>body</code> element, appears
Expand All @@ -225,10 +267,24 @@ Web Document Conformance Checker (BETA)</title>
</d:desc>
</d:item>

<d:item name="in head:head"
class="parse-error">
<d:message xml:lang="en">Start tag <code>&lt;<var>head</var>&gt;</code>
is not allowed in the <code>head</code> element.</d:message>
<d:desc xml:lang="en">
<p>There is a start tag <code>&lt;head></code> in the
<code>&lt;head></code> element. The document is non-conforming.</p>

<p>In an HTML document there must not be more than
one <code>head</code> element, therefore no more than one
start tag <code>&lt;head></code> can appear in the input stream.</p>
</d:desc>
</d:item>

<d:item name="in table"
class="parse-error">
<d:message xml:lang="en">Tag <code>&lt;<var>$0</var>&gt;</code>
is not allowed in <code>table</code>.</d:message>
is not allowed in a <code>table</code> element.</d:message>
<d:desc xml:lang="en">
<p>The start or end tag of an element, which
cannot be a child of <code>table</code> element, appears
Expand Down Expand Up @@ -546,7 +602,7 @@ Web Document Conformance Checker (BETA)</title>
<!-- @@ <id=a xml:id=a>? -->
</d:item>

<d:item name="link type:bad-context"
<d:item name="link type:bad context"
class="attribute-value-error">
<d:message xml:lang="en">The link type <code><var>$0</var></code>
cannot be specified for this element.</d:message>
Expand Down Expand Up @@ -665,7 +721,7 @@ Web Document Conformance Checker (BETA)</title>

<d:item name="URI::syntax error"
class="must" level="m">
<d:message xml:lang="en">This string is not an IRI syntactically.</d:message>
<d:message xml:lang="en">This string is syntactically not an IRI.</d:message>
</d:item>

</section>
Expand Down Expand Up @@ -813,6 +869,6 @@ manakaiIsHTML:0;;XML Document
and/or modify it under the same terms as Perl itself.</p>
</section>

<!-- $Date: 2007/07/16 13:56:26 $ -->
<!-- $Date: 2007/07/17 13:52:54 $ -->
</body>
</html>
40 changes: 37 additions & 3 deletions error-description.en.html.u8
Expand Up @@ -158,6 +158,32 @@ Web Document Conformance Checker (BETA)</title>
no effect in HTML.</p>
</div>


<div class="section tokenize-error" id="pio"><h3>Processing instruction
(<code>&lt;?<var>...</var>?&gt;</code>) cannot be used.</h3>
<p>Processing instructions (<code>&lt;?<var>...</var>?&gt;</code>),
including XML declaration (<code>&lt;?xml <var>...</var>?&gt;</code>)
and XML style sheet <abbr title="processing instruction">PI</abbr>
(<code>&lt;xml-stylesheet <var>...</var>?&gt;</code>), are not allowed
in the HTML syntax. The document is non-conforming.</p>

<p>If it is necessary to embed a processing instruction
in the HTML document, you must use the XML syntax instead.</p>

<p>In the HTML syntax, XML declaration is not necessary.</p>

<p>Instead of XML style sheet,
<abbr title="processing instruction">PI</abbr>s, you must
use the HTML <code>link</code> element whose <code>rel</code>
attribute is set to <code>stylesheet</code> (or <code>alternate
stylesheet</code> for an aleternate style sheet).</p>

<p>Web browsers will parse processing instructions as bogus
comments. Some legacy Web browsers, such as IE:mac and
some mobile browsers, will display processing instructions
as string.</p>
</div>

</section>

<section id="html5-parse-errors">
Expand All @@ -180,6 +206,14 @@ Web Document Conformance Checker (BETA)</title>
and comments can be inserted before the <code>DOCTYPE</code>.</p>
</div>

<div class="section parse-error" id="in-a:a"><h3>Anchor cannot be nested.</h3>
<p>HTML <code>a</code> elements cannot be nested.
The document is non-conforming.</p>

<p>In the HTML syntax, a start tag of the <code>a</code>
implies the end tag of any opening <code>a</code> element.</p>
</div>

<div class="section parse-error" id="in-body"><h3>Tag <code>&lt;<var>$0</var>&gt;</code>
is not allowed in <code>body</code>.</h3>
<p>The start or end tag of an element, which
Expand Down Expand Up @@ -512,7 +546,7 @@ Web Document Conformance Checker (BETA)</title>
<section id="uri-errors">
<h2>URI (or IRI) Errors</h2>

<div class="section must" id="m:URI::syntax-error"><h3>This string is not an IRI syntactically.</h3></div>
<div class="section must" id="m:URI::syntax-error"><h3>This string is syntactically not an IRI.</h3></div>

</section>

Expand All @@ -536,7 +570,7 @@ Web Document Conformance Checker (BETA)</title>

<div class="section should" id="s:URI::lowercase-hexadecimal-digit"><h3>Hexadecimal digit in percent-encoding
should be in lowercase.</h3>
<p>Hexadecimal digit in percent-encoding string in the IRI
<p>The hexadecimal digit in percent-encoding string in the IRI
is in lowercase. Though the IRI <em>is</em> conforming,
it should be in uppercase.</p>
</div>
Expand Down Expand Up @@ -610,6 +644,6 @@ Web Document Conformance Checker (BETA)</title>
and/or modify it under the same terms as Perl itself.</p>
</section>

<!-- $Date: 2007/07/16 13:56:26 $ -->
<!-- $Date: 2007/07/17 13:52:54 $ -->
</body>
</html>
Binary file added error.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added info.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 2331474

Please sign in to comment.