diff options
-rw-r--r-- | htdocs/config/charset.cfg | 96 | ||||
-rw-r--r-- | htdocs/config/check.cfg | 72 | ||||
-rw-r--r-- | htdocs/config/doctypes.cfg | 185 | ||||
-rw-r--r-- | htdocs/config/eref.cfg | 184 | ||||
-rw-r--r-- | htdocs/config/fpis.cfg | 216 | ||||
-rw-r--r-- | htdocs/config/frag.cfg | 189 | ||||
-rw-r--r-- | htdocs/config/tips.cfg | 25 | ||||
-rw-r--r-- | htdocs/config/type.cfg | 19 | ||||
-rwxr-xr-x | httpd/cgi-bin/check | 154 |
9 files changed, 725 insertions, 415 deletions
diff --git a/htdocs/config/charset.cfg b/htdocs/config/charset.cfg index 767aba0..7745c93 100644 --- a/htdocs/config/charset.cfg +++ b/htdocs/config/charset.cfg @@ -1,13 +1,13 @@ # # Mapping of 'charset' or 'encoding' parameter to conversion parameter # -# $Id: charset.cfg,v 1.6 2002-08-30 06:56:40 duerst Exp $ +# $Id: charset.cfg,v 1.7 2002-11-26 21:40:19 ville Exp $ # # this version for glibc iconv 2.1; change for other versions # # Syntax: # -# charset/encoding ? result +# charset/encoding = ? result # # Note: charsets and results are lowercase, actions are uppercase # @@ -16,53 +16,53 @@ # Note: use this also if iconv takes charset parameter directly # X: frequent error, e.g. starting with x-; ask user to replace with result -utf-16 I utf-16 -utf-16be I utf-16be -utf-16le I utf-16le -iso-8859-1 I iso-8859-1 -iso-8859-2 I iso-8859-2 -iso-8859-3 I iso-8859-3 -iso-8859-4 I iso-8859-4 -iso-8859-5 I iso-8859-5 -iso-8859-6 I iso-8859-6 +utf-16 = I utf-16 +utf-16be = I utf-16be +utf-16le = I utf-16le +iso-8859-1 = I iso-8859-1 +iso-8859-2 = I iso-8859-2 +iso-8859-3 = iso-8859-3 +iso-8859-4 = iso-8859-4 +iso-8859-5 = I iso-8859-5 +iso-8859-6 = I iso-8859-6 # implicit bidi, but character encoding is the same -iso-8859-6-i I iso-8859-6 -iso-8859-7 I iso-8859-7 -iso-8859-8 I iso-8859-8 +iso-8859-6-i = I iso-8859-6 +iso-8859-7 = I iso-8859-7 +iso-8859-8 = I iso-8859-8 # implicit bidi, but character encoding is the same -iso-8859-8-i I iso-8859-8 -iso-8859-9 I iso-8859-9 -iso-8859-10 I iso-8859-10 +iso-8859-8-i = I iso-8859-8 +iso-8859-9 = I iso-8859-9 +iso-8859-10 = I iso-8859-10 # iso-8859-11/12 don't exist yet -iso-8859-13 I iso-8859-13 -iso-8859-14 I iso-8859-14 -iso-8859-15 I iso-8859-15 -us-ascii I us-ascii -iso-2022-jp I iso-2022-jp -shift_jis I shift_jis -euc-jp I euc-jp -gb2312 I gb2312 -big5 I big5 -iso-2022-kr I iso-2022-kr -euc-kr I euc-kr -gb18030 I gb18030 -tis-620 I tis-620 -koi8-r I koi8-r -koi8-u I koi8-u -windows-1250 I cp1250 -windows-1251 I cp1251 -windows-1252 I cp1252 -windows-1253 I cp1253 -windows-1254 I cp1254 -windows-1255 I cp1255 -windows-1256 I cp1256 -windows-1257 I cp1257 -# windows-1258 I cp1258 # wait until normalization checked -macintosh I macintosh -x-mac-roman X macintosh -x-sjis X shift_jis -iso8859-1 X iso-8859-1 -ascii X us-ascii -8859_1 X iso-8859-1 +iso-8859-13 = I iso-8859-13 +iso-8859-14 = I iso-8859-14 +iso-8859-15 = I iso-8859-15 +us-ascii = I us-ascii +iso-2022-jp = I iso-2022-jp +shift_jis = I shift_jis +euc-jp = I euc-jp +gb2312 = I gb2312 +big5 = I big5 +iso-2022-kr = I iso-2022-kr +euc-kr = I euc-kr +gb18030 = I gb18030 +tis-620 = I tis-620 +koi8-r = I koi8-r +koi8-u = I koi8-u +windows-1250 = I cp1250 +windows-1251 = I cp1251 +windows-1252 = I cp1252 +windows-1253 = I cp1253 +windows-1254 = I cp1254 +windows-1255 = I cp1255 +windows-1256 = I cp1256 +windows-1257 = I cp1257 +# windows-1258 = I cp1258 # wait until normalization checked +macintosh = I macintosh +x-mac-roman = X macintosh +x-sjis = X shift_jis +iso8859-1 = X iso-8859-1 +ascii = X us-ascii +8859_1 = X iso-8859-1 # this one is in IANA, but better use only windows-1252 -iso-8859-1-Windows-3.1-Latin-1 X windows-1252 +iso-8859-1-Windows-3.1-Latin-1 = X windows-1252 diff --git a/htdocs/config/check.cfg b/htdocs/config/check.cfg index 731b4d3..e9ad9bf 100644 --- a/htdocs/config/check.cfg +++ b/htdocs/config/check.cfg @@ -1,66 +1,80 @@ # # Main Configuration File for the W3C MarkUp Validation Service. # -# $Id: check.cfg,v 1.4 2002-10-27 15:36:19 ville Exp $ +# $Id: check.cfg,v 1.5 2002-11-26 21:40:19 ville Exp $ # -# Basic Key/Value pairs, separated by TABs. -# Blank lines and lines beginning with "#" are ignored. -# -# The file:// URLs aren't really URLs; it's just convenient shorthand. -# -# TODO: -# * Document format in /docs instead of here. -# * Ditch this format for a sane one; probably using Config::General. +# See 'perldoc Config::General' for the syntax, and be aware that the +# 'SplitPolicy' is 'equalsign', ie. keys and values are separated by '\s*=\s*'. # -DEBUG 1 +DEBUG = 1 # # Email address of the maintainer of this service. -Maintainer www-validator@w3.org +Maintainer = www-validator@w3.org # # The "Home Page" for the service. -Home Page http://validator.w3.org/ +Home_Page = http://validator.w3.org/ # # Base URI To Error Explanations (doc/errors.html) -Msg FAQ URI http://validator.w3.org/docs/errors.html +Msg_FAQ_URI = http://validator.w3.org/docs/errors.html # # Base URI for the Element Reference. -Element Ref URI http://www.htmlhelp.com/reference/html40/ +Element_Ref_URI = http://www.htmlhelp.com/reference/html40/ # # The SGML Library Path. -SGML Library /usr/local/validator/htdocs/sgml-lib +SGML_Library = /var/www/html/w3c-validator/sgml-lib # -# The SGML Parser to use. -SGML Parser /usr/bin/onsgmls +# The SGML Parser to use. Defaults to /usr/bin/onsgmls. +#SGML_Parser = /usr/bin/onsgmls # # Mapping tables etc... -Element Map file:///usr/local/validator/htdocs/config/eref.cfg -FPI to Text file:///usr/local/validator/htdocs/config/fpis.cfg -Error to URI file:///usr/local/validator/htdocs/config/frag.cfg -File Type file:///usr/local/validator/htdocs/config/type.cfg -Doctypes file:///usr/local/validator/htdocs/config/doctypes.cfg -Charsets file:///usr/local/validator/htdocs/config/charset.cfg + +<Element_Map> + Include eref.cfg +</Element_Map> + +<FPI_to_Text> + Include fpis.cfg +</FPI_to_Text> + +<Error_to_URI> + Include frag.cfg +</Error_to_URI> + +<File_Type> + Include type.cfg +</File_Type> + +<Doctypes> + Include doctypes.cfg +</Doctypes> + +<Charsets> + Include charset.cfg +</Charsets> # # DanC territory... -Tips DB file:///usr/local/validator/htdocs/config/tips.cfg +<Tips_DB> + Include tips.cfg +</Tips> # # The "templates" for headers, footers... -Header /usr/local/validator/htdocs/header.html -Footer /usr/local/validator/htdocs/footer.html +Header = /var/www/html/w3c-validator/header.html +Footer = /var/www/html/w3c-validator/footer.html # -# Allowed Protocols -# - List of (comma separated) protocol schemes to allow. -Allowed Protocols http,https +# Comma separated list of protocols the validator is allowed to use for +# retrieving documents. The default is to allow http and https. +#Allowed_Protocols = http,https diff --git a/htdocs/config/doctypes.cfg b/htdocs/config/doctypes.cfg index 56a6527..8062f0f 100644 --- a/htdocs/config/doctypes.cfg +++ b/htdocs/config/doctypes.cfg @@ -1,48 +1,143 @@ # -# Mapping of HTML Version "names" to DOCTYPEs. Used for DOCTYPE overide. +# Mapping of HTML Version "names" to DOCTYPEs. Used for DOCTYPE override. # -# $Id: doctypes.cfg,v 1.8 2001-09-14 02:48:04 link Exp $ - -HTML 0.0 <!DOCTYPE html PUBLIC "-//IETF//DTD HTML Level 0//EN//2.0"> -Strict HTML 0.0 <!DOCTYPE html PUBLIC "-//IETF//DTD HTML Strict Level 0//EN//2.0"> -HTML 1.0 <!DOCTYPE html PUBLIC "-//IETF//DTD HTML 2.0 Level 1//EN"> -Strict HTML 1.0 <!DOCTYPE html PUBLIC "-//IETF//DTD HTML 2.0 Strict Level 1//EN"> -Strict HTML 2.0 <!DOCTYPE html PUBLIC "-//IETF//DTD HTML 2.0 Strict//EN"> -HTML 2.0 <!DOCTYPE html PUBLIC "-//IETF//DTD HTML 2.0//EN"> -HTML 2.1E <!DOCTYPE html PUBLIC "-//IETF//DTD HTML 2.1E//EN"> -HTML 3.0 (AdvaSoft version) <!DOCTYPE html PUBLIC "-//AS//DTD HTML 3.0 asWedit + extensions//EN"> -HTML 3.0 (Beta) <!DOCTYPE html PUBLIC "-//IETF//DTD HTML 3.0//EN"> -Strict HTML 3.0 (Beta) <!DOCTYPE html PUBLIC "-//W3O//DTD W3 HTML Strict 3.0//EN//"> -Hotjava-HTML <!DOCTYPE html PUBLIC "-//Sun Microsystems Corp.//DTD HotJava HTML//EN"> -Strict Hotjava-HTML <!DOCTYPE html PUBLIC "-//Sun Microsystems Corp.//DTD HotJava Strict HTML//EN"> -Netscape-HTML <!DOCTYPE html PUBLIC "-//WebTechs//DTD Mozilla HTML 2.0//EN"> -Strict Netscape-HTML <!DOCTYPE html PUBLIC "-//Netscape Comm. Corp. Strict//DTD HTML//EN"> -MSIE-HTML <!DOCTYPE html PUBLIC "-//Microsoft//DTD Internet Explorer 2.0 HTML//EN"> -Strict MSIE-HTML <!DOCTYPE html PUBLIC "-//Microsoft//DTD Internet Explorer 2.0 HTML Strict//EN"> -MSIE 3.0 HTML <!DOCTYPE html PUBLIC "-//Microsoft//DTD Internet Explorer 3.0 HTML//EN"> -Strict MSIE 3.0 HTML <!DOCTYPE html PUBLIC "-//Microsoft//DTD Internet Explorer 3.0 HTML Strict//EN"> -ORA HTML Extended v1.0 <!DOCTYPE html PUBLIC "-//OReilly and Associates//DTD HTML Extended 1.0//EN"> -ORA HTML Extended Relaxed v1.0 <!DOCTYPE html PUBLIC "-//OReilly and Associates//DTD HTML Extended Relaxed 1.0//EN"> -Apple Help 1.0 <!DOCTYPE HTML PUBLIC "-//bebop.net//DTD HTML Apple Help 1.0//EN" "http://www.bebop.net/AppleHelpDTD/AppleHelp1.0.dtd"> -HTML 2.2 <!DOCTYPE html PUBLIC "-//IETF//DTD HTML V2.2//EN"> -HTML 1996-01 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 1996-01//EN"> -HTML 3.2 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 3.2 Final//EN"> -HTML 3.2 + Style <!DOCTYPE html PUBLIC "-//W3C//DTD HTML Experimental 970421//EN"> -HTML Pro <!DOCTYPE html PUBLIC "+//Silmaril//DTD HTML Pro v0r11 19970101//EN"> -Spyglass HTML 2.0 Extended <!DOCTYPE html PUBLIC "-//Spyglass//DTD HTML 2.0 Extended//EN"> -HTML Level Cougar <!DOCTYPE html PUBLIC "http://www.w3.org/MarkUp/Cougar/Cougar.dtd"> -HTML 4.0 Strict <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0//EN"> -HTML 4.0 Transitional <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> -HTML 4.0 Frameset <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Frameset//EN"> -HTML 4.01 Strict <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> -HTML 4.01 Transitional <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> -HTML 4.01 Frameset <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN"> -XHTML 1.0 Strict <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> -XHTML 1.0 Transitional <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> -XHTML 1.0 Frameset <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd"> -XHTML Basic 1.0 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML Basic 1.0//EN" "http://www.w3.org/TR/xhtml-basic/xhtml-basic10.dtd"> -XHTML 1.1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> -SVG 1.0 <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN" "http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd"> -SMIL 1.0 <!DOCTYPE smil PUBLIC "-//W3C//DTD SMIL 1.0//EN" "http://www.w3.org/TR/REC-smil/SMIL10.dtd"> -SMIL 2.0 <!DOCTYPE smil PUBLIC "-//W3C//DTD SMIL 2.0//EN" "http://www.w3.org/2001/SMIL20/PR/SMIL20.dtd"> +# $Id: doctypes.cfg,v 1.9 2002-11-26 21:40:19 ville Exp $ +HTML 0.0 = \ + <!DOCTYPE html PUBLIC "-//IETF//DTD HTML Level 0//EN//2.0"> + +Strict HTML 0.0 = \ + <!DOCTYPE html PUBLIC "-//IETF//DTD HTML Strict Level 0//EN//2.0"> + +HTML 1.0 = \ + <!DOCTYPE html PUBLIC "-//IETF//DTD HTML 2.0 Level 1//EN"> + +Strict HTML 1.0 = \ + <!DOCTYPE html PUBLIC "-//IETF//DTD HTML 2.0 Strict Level 1//EN"> + +Strict HTML 2.0 = \ + <!DOCTYPE html PUBLIC "-//IETF//DTD HTML 2.0 Strict//EN"> + +HTML 2.0 = \ + <!DOCTYPE html PUBLIC "-//IETF//DTD HTML 2.0//EN"> + +HTML 2.1E = \ + <!DOCTYPE html PUBLIC "-//IETF//DTD HTML 2.1E//EN"> + +HTML 3.0 (AdvaSoft version) = \ + <!DOCTYPE html PUBLIC "-//AS//DTD HTML 3.0 asWedit + extensions//EN"> + +HTML 3.0 (Beta) = \ + <!DOCTYPE html PUBLIC "-//IETF//DTD HTML 3.0//EN"> + +Strict HTML 3.0 (Beta) = \ + <!DOCTYPE html PUBLIC "-//W3O//DTD W3 HTML Strict 3.0//EN//"> + +Hotjava-HTML = \ + <!DOCTYPE html PUBLIC "-//Sun Microsystems Corp.//DTD HotJava HTML//EN"> + +Strict Hotjava-HTML = \ + <!DOCTYPE html PUBLIC \ + "-//Sun Microsystems Corp.//DTD HotJava Strict HTML//EN"> + +Netscape-HTML = \ + <!DOCTYPE html PUBLIC "-//WebTechs//DTD Mozilla HTML 2.0//EN"> + +Strict Netscape-HTML = \ + <!DOCTYPE html PUBLIC "-//Netscape Comm. Corp. Strict//DTD HTML//EN"> + +MSIE-HTML = \ + <!DOCTYPE html PUBLIC "-//Microsoft//DTD Internet Explorer 2.0 HTML//EN"> + +Strict MSIE-HTML = \ + <!DOCTYPE html PUBLIC \ + "-//Microsoft//DTD Internet Explorer 2.0 HTML Strict//EN"> + +MSIE 3.0 HTML = \ + <!DOCTYPE html PUBLIC "-//Microsoft//DTD Internet Explorer 3.0 HTML//EN"> + +Strict MSIE 3.0 HTML = \ + <!DOCTYPE html PUBLIC \ + "-//Microsoft//DTD Internet Explorer 3.0 HTML Strict//EN"> + +ORA HTML Extended v1.0 = \ + <!DOCTYPE html PUBLIC "-//OReilly and Associates//DTD HTML Extended 1.0//EN"> + +ORA HTML Extended Relaxed v1.0 = \ + <!DOCTYPE html PUBLIC \ + "-//OReilly and Associates//DTD HTML Extended Relaxed 1.0//EN"> + +Apple Help 1.0 = \ + <!DOCTYPE HTML PUBLIC "-//bebop.net//DTD HTML Apple Help 1.0//EN" \ + "http://www.bebop.net/AppleHelpDTD/AppleHelp1.0.dtd"> + +HTML 2.2 = \ + <!DOCTYPE html PUBLIC "-//IETF//DTD HTML V2.2//EN"> + +HTML 1996-01 = \ + <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 1996-01//EN"> + +HTML 3.2 = \ + <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 3.2 Final//EN"> + +HTML 3.2 + Style = \ + <!DOCTYPE html PUBLIC "-//W3C//DTD HTML Experimental 970421//EN"> + +HTML Pro = \ + <!DOCTYPE html PUBLIC "+//Silmaril//DTD HTML Pro v0r11 19970101//EN"> + +Spyglass HTML 2.0 Extended = \ + <!DOCTYPE html PUBLIC "-//Spyglass//DTD HTML 2.0 Extended//EN"> + +HTML Level Cougar = \ + <!DOCTYPE html PUBLIC "http://www.w3.org/MarkUp/Cougar/Cougar.dtd"> + +HTML 4.0 Strict = \ + <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0//EN"> + +HTML 4.0 Transitional = \ + <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> + +HTML 4.0 Frameset = \ + <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Frameset//EN"> + +HTML 4.01 Strict = \ + <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> + +HTML 4.01 Transitional = \ + <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> + +HTML 4.01 Frameset = \ + <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN"> + +XHTML 1.0 Strict = \ + <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" \ + "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> + +XHTML 1.0 Transitional = \ + <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" \ + "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> + +XHTML 1.0 Frameset = \ + <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN" \ + "http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd"> + +XHTML Basic 1.0 = \ + <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML Basic 1.0//EN" \ + "http://www.w3.org/TR/xhtml-basic/xhtml-basic10.dtd"> + +XHTML 1.1 = \ + <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" \ + "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> + +SVG 1.0 = \ + <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN" \ + "http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd"> + +SMIL 1.0 = \ + <!DOCTYPE smil PUBLIC "-//W3C//DTD SMIL 1.0//EN" \ + "http://www.w3.org/TR/REC-smil/SMIL10.dtd"> + +SMIL 2.0 = \ + <!DOCTYPE smil PUBLIC "-//W3C//DTD SMIL 2.0//EN" \ + "http://www.w3.org/2001/SMIL20/PR/SMIL20.dtd"> diff --git a/htdocs/config/eref.cfg b/htdocs/config/eref.cfg index cc30d5f..271c198 100644 --- a/htdocs/config/eref.cfg +++ b/htdocs/config/eref.cfg @@ -1,96 +1,96 @@ # # Mapping of element names to an URI fragment for their definition. # -# $Id: eref.cfg,v 1.1 1999-12-01 01:04:06 gerald Exp $ +# $Id: eref.cfg,v 1.2 2002-11-26 21:40:19 ville Exp $ -a special/a.html -abbr phrase/abbr.html -acronym phrase/acronym.html -address block/address.html -applet special/applet.html -area special/area.html -b fontstyle/b.html -base head/base.html -basefont special/basefont.html -bdo special/bdo.html -big fontstyle/big.html -blockquote block/blockquote.html -body html/body.html -br special/br.html -button forms/button.html -caption tables/caption.html -center block/center.html -cite phrase/cite.html -code phrase/code.html -col tables/col.html -colgroup tables/colgroup.html -dd lists/dd.html -del phrase/del.html -dfn phrase/dfn.html -dir lists/dir.html -div block/div.html -dl lists/dl.html -dt lists/dt.html -em phrase/em.html -fieldset forms/fieldset.html -font special/font.html -form forms/form.html -frame frames/frame.html -frameset frames/frameset.html -h1 block/h1.html -h2 block/h2.html -h3 block/h3.html -h4 block/h4.html -h5 block/h5.html -h6 block/h6.html -head head/head.html -hr block/hr.html -html html/html.html -i fontstyle/i.html -iframe special/iframe.html -img special/img.html -input forms/input.html -ins phrase/ins.html -isindex block/isindex.html -kbd phrase/kbd.html -label forms/label.html -legend forms/legend.html -li lists/li.html -link head/link.html -map special/map.html -menu lists/menu.html -meta head/meta.html -noframes frames/noframes.html -noscript block/noscript.html -object special/object.html -ol lists/ol.html -optgroup forms/optgroup.html -option forms/option.html -p block/p.html -param special/param.html -pre block/pre.html -q special/q.html -s fontstyle/s.html -samp phrase/samp.html -script special/script.html -select forms/select.html -small fontstyle/small.html -span special/span.html -strike fontstyle/strike.html -strong phrase/strong.html -style head/style.html -sub special/sub.html -sup special/sup.html -table tables/table.html -tbody tables/tbody.html -td tables/td.html -textarea forms/textarea.html -tfoot tables/tfoot.html -th tables/th.html -thead tables/thead.html -title head/title.html -tr tables/tr.html -tt fontstyle/tt.html -u fontstyle/u.html -ul lists/ul.html -var phrase/var.html +a = special/a.html +abbr = phrase/abbr.html +acronym = phrase/acronym.html +address = block/address.html +applet = special/applet.html +area = special/area.html +b = fontstyle/b.html +base = head/base.html +basefont = special/basefont.html +bdo = special/bdo.html +big = fontstyle/big.html +blockquote = block/blockquote.html +body = html/body.html +br = special/br.html +button = forms/button.html +caption = tables/caption.html +center = block/center.html +cite = phrase/cite.html +code = phrase/code.html +col = tables/col.html +colgroup = tables/colgroup.html +dd = lists/dd.html +del = phrase/del.html +dfn = phrase/dfn.html +dir = lists/dir.html +div = block/div.html +dl = lists/dl.html +dt = lists/dt.html +em = phrase/em.html +fieldset = forms/fieldset.html +font = special/font.html +form = forms/form.html +frame = frames/frame.html +frameset = frames/frameset.html +h1 = block/h1.html +h2 = block/h2.html +h3 = block/h3.html +h4 = block/h4.html +h5 = block/h5.html +h6 = block/h6.html +head = head/head.html +hr = block/hr.html +html = html/html.html +i = fontstyle/i.html +iframe = special/iframe.html +img = special/img.html +input = forms/input.html +ins = phrase/ins.html +isindex = block/isindex.html +kbd = phrase/kbd.html +label = forms/label.html +legend = forms/legend.html +li = lists/li.html +link = head/link.html +map = special/map.html +menu = lists/menu.html +meta = head/meta.html +noframes = frames/noframes.html +noscript = block/noscript.html +object = special/object.html +ol = lists/ol.html +optgroup = forms/optgroup.html +option = forms/option.html +p = block/p.html +param = special/param.html +pre = block/pre.html +q = special/q.html +s = fontstyle/s.html +samp = phrase/samp.html +script = special/script.html +select = forms/select.html +small = fontstyle/small.html +span = special/span.html +strike = fontstyle/strike.html +strong = phrase/strong.html +style = head/style.html +sub = special/sub.html +sup = special/sup.html +table = tables/table.html +tbody = tables/tbody.html +td = tables/td.html +textarea = forms/textarea.html +tfoot = tables/tfoot.html +th = tables/th.html +thead = tables/thead.html +title = head/title.html +tr = tables/tr.html +tt = fontstyle/tt.html +u = fontstyle/u.html +ul = lists/ul.html +var = phrase/var.html diff --git a/htdocs/config/fpis.cfg b/htdocs/config/fpis.cfg index 92995cc..a5d82a4 100644 --- a/htdocs/config/fpis.cfg +++ b/htdocs/config/fpis.cfg @@ -1,66 +1,158 @@ # # Mapping of FPIs to plain text version strings. # -# $Id: fpis.cfg,v 1.16 2001-09-14 02:48:04 link Exp $ - --//IETF//DTD HTML Level 0//EN//2.0 HTML 0.0 --//IETF//DTD HTML Strict Level 0//EN//2.0 Strict HTML 0.0 - --//IETF//DTD HTML 2.0 Level 1//EN HTML 1.0 --//IETF//DTD HTML 2.0 Strict Level 1//EN Strict HTML 1.0 - --//IETF//DTD HTML 2.0 Strict//EN Strict HTML 2.0 --//IETF//DTD HTML 2.0//EN HTML 2.0 --//IETF//DTD HTML 2.1E//EN HTML 2.1E - --//AS//DTD HTML 3.0 asWedit + extensions//EN HTML 3.0 (AdvaSoft version) --//IETF//DTD HTML 3.0//EN HTML 3.0 (Beta) --//W3O//DTD W3 HTML Strict 3.0//EN// Strict HTML 3.0 (Beta) - --//Sun Microsystems Corp.//DTD HotJava HTML//EN Hotjava-HTML --//Sun Microsystems Corp.//DTD HotJava Strict HTML//EN Strict Hotjava-HTML --//WebTechs//DTD Mozilla HTML 2.0//EN Netscape-HTML --//Netscape Comm. Corp. Strict//DTD HTML//EN Strict Netscape-HTML --//Microsoft//DTD Internet Explorer 2.0 HTML//EN MSIE-HTML --//Microsoft//DTD Internet Explorer 2.0 HTML Strict//EN Strict MSIE-HTML --//Microsoft//DTD Internet Explorer 3.0 HTML//EN MSIE 3.0 HTML --//Microsoft//DTD Internet Explorer 3.0 HTML Strict//EN Strict MSIE 3.0 HTML --//OReilly and Associates//DTD HTML Extended 1.0//EN O\'Reilly HTML Extended v1.0 --//OReilly and Associates//DTD HTML Extended Relaxed 1.0//EN O\'Reilly HTML Extended Relaxed v1.0 --//bebop.net//DTD HTML Apple Help 1.0//EN Apple Help 1.0 - --//IETF//DTD HTML V2.2//EN HTML 2.2 --//W3C//DTD HTML 1996-01//EN HTML 1996-01 --//W3C//DTD HTML 3.2 Final//EN <a href="http://www.w3.org/TR/REC-html32">HTML 3.2</a> --//W3C//DTD HTML Experimental 970421//EN <a href="http://www.w3.org/TR/NOTE-html-970421.html">HTML 3.2 + Style</a> -+//Silmaril//DTD HTML Pro v0r11 19970101//EN <a href="http://www.ucc.ie/doc/www/html/dtds/htmlpro.html">HTML Pro</a> --//Spyglass//DTD HTML 2.0 Extended//EN Spyglass HTML 2.0 Extended -http://www.w3.org/MarkUp/Cougar/Cougar.dtd <a href="http://www.w3.org/MarkUp/Cougar/">HTML Level "Cougar"</a> --//W3C//DTD HTML 4.0//EN <a href="http://www.w3.org/TR/1998/REC-html40-19980424/">HTML 4.0</a> Strict --//W3C//DTD HTML 4.0 Transitional//EN <a href="http://www.w3.org/TR/1998/REC-html40-19980424/">HTML 4.0</a> Transitional --//W3C//DTD HTML 4.0 Frameset//EN <a href="http://www.w3.org/TR/1998/REC-html40-19980424/">HTML 4.0</a> Frameset --//W3C//DTD HTML 4.01//EN <a href="http://www.w3.org/TR/1999/REC-html401-19991224/">HTML 4.01</a> Strict --//W3C//DTD HTML 4.01 Transitional//EN <a href="http://www.w3.org/TR/1999/REC-html401-19991224/">HTML 4.01</a> Transitional --//W3C//DTD HTML 4.01 Frameset//EN <a href="http://www.w3.org/TR/1999/REC-html401-19991224/">HTML 4.01</a> Frameset --//W3C//DTD XHTML 1.0 Strict//EN <a href="http://www.w3.org/TR/2000/REC-xhtml1-20000126/">XHTML 1.0</a> Strict --//W3C//DTD XHTML 1.0 Transitional//EN <a href="http://www.w3.org/TR/2000/REC-xhtml1-20000126/">XHTML 1.0</a> Transitional --//W3C//DTD XHTML 1.0 Frameset//EN <a href="http://www.w3.org/TR/2000/REC-xhtml1-20000126/">XHTML 1.0</a> Frameset -XML <a href="http://www.w3.org/TR/REC-xml">XML</a> - -ISO/IEC 15445:2000//DTD HyperText Markup Language//EN <a href="http://purl.org/NET/ISO+IEC.15445/15445.html">ISO/IEC 15445:2000</a> (ISO-HTML) -ISO/IEC 15445:2000//DTD HTML//EN <a href="http://purl.org/NET/ISO+IEC.15445/15445.html">ISO/IEC 15445:2000</a> (ISO-HTML) - --//W3C//DTD MathML 2.0//EN <a href="http://www.w3.org/TR/MathML2/">MathML 2.0</a> --//W3C//DTD XHTML 1.1 plus MathML 2.0//EN <a href="http://www.w3.org/TR/MathML2/">XHTML 1.1 plus MathML 2.0</a> - --//W3C//DTD XHTML Basic 1.0//EN <a href="http://www.w3.org/TR/2000/REC-xhtml-basic-20001219/">XHTML Basic 1.0</a> - --//W3C//DTD XHTML 1.1//EN <a href="http://www.w3.org/TR/2001/REC-xhtml11-20010531/">XHTML 1.1</a> - --//W3C//DTD SVG 1.0//EN <a href="http://www.w3.org/TR/2001/REC-SVG-20010904/">SVG 1.0</a> - --//W3C//DTD SVG 20010719//EN <a href="http://www.w3.org/TR/2001/PR-SVG-20010719/">SVG 1.0 PR 20010719</a> - --//W3C//DTD SMIL 1.0//EN <a href="http://www.w3.org/TR/1998/REC-smil-19980615/">SMIL 1.0</a> --//W3C//DTD SMIL 2.0//EN <a href="http://www.w3.org/TR/2001/PR-smil20-20010605/">SMIL 2.0</a> +# $Id: fpis.cfg,v 1.17 2002-11-26 21:40:19 ville Exp $ +-//IETF//DTD HTML Level 0//EN//2.0 = \ + HTML 0.0 + +-//IETF//DTD HTML Strict Level 0//EN//2.0 = \ + Strict HTML 0.0 + +-//IETF//DTD HTML 2.0 Level 1//EN = \ + HTML 1.0 + +-//IETF//DTD HTML 2.0 Strict Level 1//EN = \ + Strict HTML 1.0 + +-//IETF//DTD HTML 2.0 Strict//EN = \ + Strict HTML 2.0 + +-//IETF//DTD HTML 2.0//EN = \ + HTML 2.0 + +-//IETF//DTD HTML 2.1E//EN = \ + HTML 2.1E + +-//AS//DTD HTML 3.0 asWedit + extensions//EN = \ + HTML 3.0 (AdvaSoft version) + +-//IETF//DTD HTML 3.0//EN = \ + HTML 3.0 (Beta) + +-//W3O//DTD W3 HTML Strict 3.0//EN// = \ + Strict HTML 3.0 (Beta) + +-//Sun Microsystems Corp.//DTD HotJava HTML//EN = \ + Hotjava-HTML + +-//Sun Microsystems Corp.//DTD HotJava Strict HTML//EN = \ + Strict Hotjava-HTML + +-//WebTechs//DTD Mozilla HTML 2.0//EN = \ + Netscape-HTML + +-//Netscape Comm. Corp. Strict//DTD HTML//EN = \ + Strict Netscape-HTML + +-//Microsoft//DTD Internet Explorer 2.0 HTML//EN = \ + MSIE-HTML + +-//Microsoft//DTD Internet Explorer 2.0 HTML Strict//EN = \ + Strict MSIE-HTML + +-//Microsoft//DTD Internet Explorer 3.0 HTML//EN = \ + MSIE 3.0 HTML + +-//Microsoft//DTD Internet Explorer 3.0 HTML Strict//EN + Strict MSIE 3.0 HTML + +-//OReilly and Associates//DTD HTML Extended 1.0//EN = \ + O'Reilly HTML Extended v1.0 + +-//OReilly and Associates//DTD HTML Extended Relaxed 1.0//EN = \ + O'Reilly HTML Extended Relaxed v1.0 + +-//bebop.net//DTD HTML Apple Help 1.0//EN = \ + Apple Help 1.0 + +-//IETF//DTD HTML V2.2//EN = \ + HTML 2.2 + +-//W3C//DTD HTML 1996-01//EN = \ + HTML 1996-01 + +-//W3C//DTD HTML 3.2 Final//EN = \ + <a href="http://www.w3.org/TR/REC-html32">HTML 3.2</a> + +-//W3C//DTD HTML Experimental 970421//EN = \ + <a href="http://www.w3.org/TR/NOTE-html-970421.html">HTML 3.2 + Style</a> + ++//Silmaril//DTD HTML Pro v0r11 19970101//EN = \ + <a href="http://www.ucc.ie/doc/www/html/dtds/htmlpro.html">HTML Pro</a> + +-//Spyglass//DTD HTML 2.0 Extended//EN = \ + Spyglass HTML 2.0 Extended + +http://www.w3.org/MarkUp/Cougar/Cougar.dtd = \ + <a href="http://www.w3.org/MarkUp/Cougar/">HTML Level Cougar"</a> + +-//W3C//DTD HTML 4.0//EN = \ + <a href="http://www.w3.org/TR/1998/REC-html40-19980424/">HTML 4.0</a> Strict + +-//W3C//DTD HTML 4.0 Transitional//EN = \ + <a href="http://www.w3.org/TR/1998/REC-html40-19980424/">HTML 4.0</a> \ + Transitional + +-//W3C//DTD HTML 4.0 Frameset//EN = \ + <a href="http://www.w3.org/TR/1998/REC-html40-19980424/">HTML 4.0</a> \ + Frameset + +-//W3C//DTD HTML 4.01//EN = \ + <a href="http://www.w3.org/TR/1999/REC-html401-19991224/">HTML 4.01</a> \ + Strict + +-//W3C//DTD HTML 4.01 Transitional//EN = \ + <a href="http://www.w3.org/TR/1999/REC-html401-19991224/">HTML 4.01</a> \ + Transitional + +-//W3C//DTD HTML 4.01 Frameset//EN = \ + <a href="http://www.w3.org/TR/1999/REC-html401-19991224/">HTML 4.01</a> \ + Frameset + +-//W3C//DTD XHTML 1.0 Strict//EN = \ + <a href="http://www.w3.org/TR/2000/REC-xhtml1-20000126/">XHTML 1.0</a> Strict + +-//W3C//DTD XHTML 1.0 Transitional//EN = \ + <a href="http://www.w3.org/TR/2000/REC-xhtml1-20000126/">XHTML 1.0</a> \ + Transitional + +-//W3C//DTD XHTML 1.0 Frameset//EN = \ + <a href="http://www.w3.org/TR/2000/REC-xhtml1-20000126/">XHTML 1.0</a> \ + Frameset + +XML = \ + <a href="http://www.w3.org/TR/REC-xml">XML</a> + +ISO/IEC 15445:2000//DTD HyperText Markup Language//EN = \ + <a href="http://purl.org/NET/ISO+IEC.15445/15445.html">ISO/IEC \ + 15445:2000</a> (ISO-HTML) + +ISO/IEC 15445:2000//DTD HTML//EN = \ + <a href="http://purl.org/NET/ISO+IEC.15445/15445.html">ISO/IEC \ + 15445:2000</a> (ISO-HTML) + +-//W3C//DTD MathML 2.0//EN = \ + <a href="http://www.w3.org/TR/MathML2/">MathML 2.0</a> + +-//W3C//DTD XHTML 1.1 plus MathML 2.0//EN = \ + <a href="http://www.w3.org/TR/MathML2/">XHTML 1.1 plus MathML 2.0</a> + +-//W3C//DTD XHTML Basic 1.0//EN = \ + <a href="http://www.w3.org/TR/2000/REC-xhtml-basic-20001219/">XHTML Basic \ + 1.0</a> + +-//W3C//DTD XHTML 1.1//EN = \ + <a href="http://www.w3.org/TR/2001/REC-xhtml11-20010531/">XHTML 1.1</a> + +-//W3C//DTD SVG 1.0//EN = \ + <a href="http://www.w3.org/TR/2001/REC-SVG-20010904/">SVG 1.0</a> + +-//W3C//DTD SVG 20010719//EN = \ + <a href="http://www.w3.org/TR/2001/PR-SVG-20010719/">SVG 1.0 PR 20010719</a> + +-//W3C//DTD SMIL 1.0//EN = \ + <a href="http://www.w3.org/TR/1998/REC-smil-19980615/">SMIL 1.0</a> + +-//W3C//DTD SMIL 2.0//EN = \ + <a href="http://www.w3.org/TR/2001/PR-smil20-20010605/">SMIL 2.0</a> diff --git a/htdocs/config/frag.cfg b/htdocs/config/frag.cfg index 253cffa..dffae37 100644 --- a/htdocs/config/frag.cfg +++ b/htdocs/config/frag.cfg @@ -1,62 +1,161 @@ # # Mapping of error message to URI fragment for the explanations. # -# $Id: frag.cfg,v 1.5 2002-10-29 06:39:49 ville Exp $ +# $Id: frag.cfg,v 1.6 2002-11-26 21:40:19 ville Exp $ # # Original SP version. -entity end not allowed in comment unterm-comment-1 -name start character invalid only s and comment allowed in comment declaration unterm-comment-2 -name character invalid only s and comment allowed in comment declaration unterm-comment-2 -unknown declaration type FOO bad-comment -character FOO not allowed in attribute specification list attr-char -an attribute value must be a literal unless it contains only name characters attr-quoted -syntax of attribute value does not conform to declared value bad-attr-char -length of attribute value must not exceed LITLEN less NORMSEP name-length -element FOO undefined undef-tag -element FOO not allowed here not-allowed -there is no attribute FOO attr-undef -FOO is not a member of the group specified in the declared value of this attribute undef-attr-val -FOO is not a member of a group specified for any attribute bad-abbrev-attr -end tag for FOO omitted but its declaration does not permit this no-end-tag -end tag for element FOO which is not open floating-close -end tag for FOO which is not finished omitted-content -start tag for FOO omitted but its declaration does not permit this no-start-tag -general entity FOO not defined and no default entity bad-entity -non SGML character number bad-char -cannot generate system identifier for entity FOO bad-pub-id -ID FOO already defined dup-id -ID FOO first defined here dup-id +# + +entity end not allowed in comment = \ + unterm-comment-1 + +name start character invalid only s and comment allowed in comment \ + declaration = \ + unterm-comment-2 + +name character invalid only s and comment allowed in comment declaration = \ + unterm-comment-2 + +unknown declaration type FOO = \ + bad-comment + +character FOO not allowed in attribute specification list = \ + attr-char + +an attribute value must be a literal unless it contains only name characters =\ + attr-quoted + +syntax of attribute value does not conform to declared value = \ + bad-attr-char + +length of attribute value must not exceed LITLEN less NORMSEP = \ + name-length + +element FOO undefined = \ + undef-tag + +element FOO not allowed here = \ + not-allowed + +there is no attribute FOO = \ + attr-undef + +FOO is not a member of the group specified in the declared value of this \ + attribute = \ + undef-attr-val + +FOO is not a member of a group specified for any attribute = \ + bad-abbrev-attr + +end tag for FOO omitted but its declaration does not permit this = \ + no-end-tag + +end tag for element FOO which is not open = \ + floating-close + +end tag for FOO which is not finished = \ + omitted-content + +start tag for FOO omitted but its declaration does not permit this = \ + no-start-tag + +general entity FOO not defined and no default entity = \ + bad-entity + +non SGML character number = \ + bad-char + +cannot generate system identifier for entity FOO = \ + bad-pub-id + +ID FOO already defined = \ + dup-id + +ID FOO first defined here = \ + dup-id # # Horribly verbose versions from lq-nsgmls. -document type does not allow element FOO here not-allowed-contained -there is no attribute FOO for this element in this HTML version attr-undef -an attribute value must be quoted if it contains any character other than letters AZaz digits hyphens and periods use quotes if in doubt attr-quoted -element FOO not allowed here possible cause is an inline element containing a blocklevel element not-allowed -element FOO not allowed here check which elements this element may be contained within not-allowed -missing a required subelement of FOO missing-subel -unknown entity FOO bad-entity -end tag for FOO omitted possible causes include a missing end tag improper nesting of elements or use of an element where it is not allowed no-end-tag -start tag was here start-tag -end tag for element FOO which is not open try removing the end tag or check for improper nesting of elements floating-close -element FOO not defined in this HTML version undef-tag -required attribute FOO not specified attr-missing -text is not allowed here try wrapping the text in a more descriptive container text-not-allowed -value of attribute FOO cannot be FOO must be one of FOO unkn-att-val -character FOO not allowed in attribute specification list possibly caused by a missing quotation mark ending a previous attribute value no-attr-end -reference to nonSGML character bad-char -duplicate specification of attribute FOO dup-attr -an attribute specification must start with a name or name token attr-spec-nmtoken -invalid comment declaration check your comment syntax inval-comment -comment declaration started here inval-comment -element FOO not allowed here assuming missing FOO starttag assuming-missing-starttag +# + +document type does not allow element FOO here = \ + not-allowed-contained + +there is no attribute FOO for this element in this HTML version = \ + attr-undef + +an attribute value must be quoted if it contains any character other than \ + letters AZaz digits hyphens and periods use quotes if in doubt = \ + attr-quoted + +element FOO not allowed here possible cause is an inline element containing a \ + blocklevel element = \ + not-allowed + +element FOO not allowed here check which elements this element may be \ + contained within = \ + not-allowed + +missing a required subelement of FOO = \ + missing-subel + +unknown entity FOO = \ + bad-entity + +end tag for FOO omitted possible causes include a missing end tag improper \ + nesting of elements or use of an element where it is not allowed = \ + no-end-tag + +start tag was here = \ + start-tag + +end tag for element FOO which is not open try removing the end tag or check \ + for improper nesting of elements = \ + floating-close + +element FOO not defined in this HTML version = \ + undef-tag +required attribute FOO not specified = \ + attr-missing + +text is not allowed here try wrapping the text in a more descriptive \ + container = \ + text-not-allowed + +value of attribute FOO cannot be FOO must be one of FOO = \ + unkn-att-val + +character FOO not allowed in attribute specification list possibly caused by \ + a missing quotation mark ending a previous attribute value = \ + no-attr-end + +reference to nonSGML character = \ + bad-char + +duplicate specification of attribute FOO = \ + dup-attr + +an attribute specification must start with a name or name token = \ + attr-spec-nmtoken + +invalid comment declaration check your comment syntax = \ + inval-comment + +comment declaration started here = \ + inval-comment + +element FOO not allowed here assuming missing FOO starttag = \ + assuming-missing-starttag # # Reported but not yet explained... + FOO not finished but containing element ended # # Doesn't work for some reason..? -invalid attribute value invalid-attr-val + +invalid attribute value = \ + invalid-attr-val diff --git a/htdocs/config/tips.cfg b/htdocs/config/tips.cfg index 212fede..e2dd75f 100644 --- a/htdocs/config/tips.cfg +++ b/htdocs/config/tips.cfg @@ -5,13 +5,24 @@ # the link to it. Will appear in Validation Results pages. To disable # just comment out or delete all lines in this file. # -# $Id: tips.cfg,v 1.3 2002-09-29 22:15:19 link Exp $ +# $Id: tips.cfg,v 1.4 2002-11-26 21:40:19 ville Exp $ # -http://www.w3.org/2001/06tips/good-titles <strong><title></strong>: the most important element of a quality Web page. -http://www.w3.org/2001/06tips/noClickHere Don't use "click here" as link text! -http://www.w3.org/2001/06tips/Use_h1_for_Title Use h1 for title! -http://www.w3.org/2001/06tips/reback Use standard redirects: don't break the back button! -http://www.w3.org/2001/06tips/Doctype Don't forget to add a doctype! -http://www.w3.org/Provider/Style/URI Cool URIs don't change! +http://www.w3.org/2001/06tips/good-titles = \ + <strong><title></strong>: \ + the most important element of a quality Web page. +http://www.w3.org/2001/06tips/noClickHere = \ + Don't use "click here" as link text! + +http://www.w3.org/2001/06tips/Use_h1_for_Title = \ + Use h1 for title! + +http://www.w3.org/2001/06tips/reback = \ + Use standard redirects: don't break the back button! + +http://www.w3.org/2001/06tips/Doctype = \ + Don't forget to add a doctype! + +http://www.w3.org/Provider/Style/URI = \ + Cool URIs don't change! diff --git a/htdocs/config/type.cfg b/htdocs/config/type.cfg index c27ea3b..cc80467 100644 --- a/htdocs/config/type.cfg +++ b/htdocs/config/type.cfg @@ -1,14 +1,13 @@ # # Mapping of Content-Type to document type. # -# $Id: type.cfg,v 1.5 2002-08-20 01:51:24 link Exp $ - -text/xml xml+xml -image/svg svg+xml -image/svg+xml svg+xml -application/smil smil+xml -application/xml xml+xml -text/html html -text/vnd.wap.wml xml+xml -application/xhtml+xml html+xml +# $Id: type.cfg,v 1.6 2002-11-26 21:40:19 ville Exp $ +text/xml = xml+xml +image/svg = svg+xml +image/svg+xml = svg+xml +application/smil = smil+xml +application/xml = xml+xml +text/html = html +text/vnd.wap.wml = xml+xml +application/xhtml+xml = html+xml diff --git a/httpd/cgi-bin/check b/httpd/cgi-bin/check index c968863..a346d57 100755 --- a/httpd/cgi-bin/check +++ b/httpd/cgi-bin/check @@ -9,7 +9,7 @@ # This source code is available under the license at: # http://www.w3.org/Consortium/Legal/copyright-software # -# $Id: check,v 1.305 2002-11-25 19:24:51 ville Exp $ +# $Id: check,v 1.306 2002-11-26 21:40:19 ville Exp $ # # Disable buffering on STDOUT! @@ -36,19 +36,20 @@ use warnings; # when loading modules to prevent non-OO or poorly written modules from # polluting our namespace. # -use CGI 2.81 qw(-newstyle_urls -private_tempfiles); # 2.81 for XHTML -use CGI::Carp qw(carp croak); -use File::Spec qw(); -use HTML::Parser 3.25 qw(); # Need 3.25 for $p->ignore_elements. -use HTTP::Request qw(); -use IO::File qw(); -use IPC::Open3 qw(open3); -use LWP::UserAgent 1.90 qw(); # Need 1.90 for protocols_(allowed|forbidden) -use Set::IntSpan qw(); -use Text::Iconv qw(); -use Text::Wrap qw(wrap); -use URI qw(); -use URI::Escape qw(uri_escape); +use CGI 2.81 qw(-newstyle_urls -private_tempfiles); # 2.81: XHTML +use CGI::Carp qw(carp croak); +use Config::General 2.06 qw(); # Need 2.06 for -SplitPolicy +use File::Spec qw(); +use HTML::Parser 3.25 qw(); # Need 3.25 for $p->ignore_elements. +use HTTP::Request qw(); +use IO::File qw(); +use IPC::Open3 qw(open3); +use LWP::UserAgent 1.90 qw(); # Need 1.90 for protocols_(allowed|forbidden) +use Set::IntSpan qw(); +use Text::Iconv qw(); +use Text::Wrap qw(wrap); +use URI qw(); +use URI::Escape qw(uri_escape); ############################################################################### @@ -87,7 +88,36 @@ BEGIN { # # Read Config Files. - $CFG = &read_cfg($ENV{W3C_VALIDATOR_CFG} || '/etc/w3c/validator.conf'); + eval { + my %config_opts = + (-ConfigFile => $ENV{W3C_VALIDATOR_CFG} || '/etc/w3c/validator.conf', + -MergeDuplicateOptions => 'yes', + -SplitPolicy => 'equalsign', + -UseApacheInclude => 1, + -IncludeRelative => 1, + -DefaultConfig => { Allowed_Protocols => 'http,https', + SGML_Parser => '/usr/bin/onsgmls', + }, + ); + my %cfg = Config::General->new(%config_opts)->getall(); + $CFG = \%cfg; + }; + if ($@) { + die <<".EOF."; +Couldn't read configuration. Set the W3C_VALIDATOR_CFG environment variable +or copy conf/* to /etc/w3c/, and make sure that the configuration file, as +well as all included files are readable by the web server user. +The error reported was: '$@' +.EOF. + } + # Split allowed protocols into a list. + # We could use the array / identical values feature of Config::General, + # but that has unwanted effects when the only array type option we need is + # Allowed_Protocols. + if (my $allowed = delete($CFG->{Allowed_Protocols})) { + $CFG->{Allowed_Protocols} = [ split(/\s*,\s*/, $allowed) ]; + } + # # Set debug flag. @@ -95,40 +125,9 @@ BEGIN { # # Strings - $VERSION = q$Revision: 1.305 $; + $VERSION = q$Revision: 1.306 $; $VERSION =~ s/Revision: ([\d\.]+) /$1/; - - # - # Read TAB-delimited configuration files. Returns a hash reference. - sub read_cfg { - my $file = shift; - my %cfg; - - my $fh = new IO::File $file; - unless (defined $fh) { - die <<".EOF."; -open($file) returned: $! -(Did you forget to set \$ENV{W3C_VALIDATOR_CFG} - or to copy htdocs/config/check.cfg to /etc/w3c/validator.conf?) -.EOF. - } - - while (<$fh>) { - next if /^\s*$/; - next if /^\s*\#/; - chomp; - my($k, $v) = split /\t+/, $_, 2; - $v = '' unless defined $v; - - if ($v =~ s(^file://){}) {$cfg{$k} = &read_cfg($v) } - elsif ($v =~ /,/) {$cfg{$k} = [split /,/, $v]} - else {$cfg{$k} = $v } - } - undef $fh; - return \%cfg; - } - } # end of BEGIN block. # @@ -151,13 +150,13 @@ my $File; # # Pseudo-SSI include header and footer for output. $File->{'Header'} = &prepSSI({ - File => $CFG->{'Header'}, + File => $CFG->{Header}, Title => 'Validation Results', Revision => $VERSION, }); $File->{'Footer'} = &prepSSI({ - File => $CFG->{'Footer'}, - Date => q$Date: 2002-11-25 19:24:51 $, + File => $CFG->{Footer}, + Date => q$Date: 2002-11-26 21:40:19 $, }); # @@ -448,7 +447,7 @@ if ($File->{'Is Upload'}) { # # By default, use SGML catalog file and SGML Declaration. -my $catalog = File::Spec->catfile($CFG->{'SGML Library'}, 'sgml.soc'); +my $catalog = File::Spec->catfile($CFG->{SGML_Library}, 'sgml.soc'); my @xmlflags = qw( -R -wvalid @@ -459,7 +458,7 @@ my @xmlflags = qw( # # Switch to XML semantics if file is XML. if (&is_xml($File->{Type})) { - $catalog = File::Spec->catfile($CFG->{'SGML Library'}, 'xml.soc'); + $catalog = File::Spec->catfile($CFG->{SGML_Library}, 'xml.soc'); push(@xmlflags, '-wxml'); &add_warning($File, <<".EOF."); <em>Note</em>: The Validator XML support has @@ -477,7 +476,7 @@ $ENV{SP_BCTF} = 'UTF-8'; # # Tell onsgmls about the SGML Library. -$ENV{SGML_SEARCH_PATH} = $CFG->{'SGML Library'}; +$ENV{SGML_SEARCH_PATH} = $CFG->{SGML_Library}; ## @@ -485,20 +484,20 @@ $ENV{SGML_SEARCH_PATH} = $CFG->{'SGML Library'}; #if (&is_html($File->{Type})) { # $ENV{SP_CHARSET_FIXED} = 'YES'; # $ENV{SP_ENCODING} = 'UTF-8'; -# $catalog = File::Spec->catfile($CFG->{'SGML Library'}, 'catalog'); +# $catalog = File::Spec->catfile($CFG->{SGML_Library}, 'catalog'); # @xmlflags = '-wnon-sgml-char-ref'; #} ## ## MathML and XHTML. Must be here because they're usually served as text/html ## to deal with braindead browsers. In other words, these override the check for &is_html. -#$catalog = File::Spec->catfile($CFG->{'SGML Library'}, 'xhtml.soc') +#$catalog = File::Spec->catfile($CFG->{SGML_Library}, 'xhtml.soc') # if &is_xhtml($File->{Type}); -#$catalog = File::Spec->catfile($CFG->{'SGML Library'}, 'mathml.soc') +#$catalog = File::Spec->catfile($CFG->{SGML_Library}, 'mathml.soc') # if &is_mathml($File->{Type}); -my @cmd = ($CFG->{'SGML Parser'}, '-c', $catalog, '-E0', @xmlflags); +my @cmd = ($CFG->{SGML_Parser}, '-c', $catalog, '-E0', @xmlflags); if ($DEBUG) { &add_table($File, 'Command', @@ -605,7 +604,7 @@ if (&is_xml($File->{Type}) and not $File->{DOCTYPE}) { # # Get the pretty text version of the FPI if a mapping exists. -if (my $prettyver = $CFG->{'FPI to Text'}->{$File->{Version}}) { +if (my $prettyver = $CFG->{FPI_to_Text}->{$File->{Version}}) { $File->{Version} = $prettyver; } else { $File->{Version} = &ent($File->{Version}); @@ -991,7 +990,7 @@ Content-Type: text/html; charset=utf-8 Of course, you may not want to trust me with this information, which is fine. I can tell you that I don't log it or do anything else nasty with it, and you can <a - href="$CFG->{'Home Page'}source/">download the source for + href="$CFG->{Home_Page}source/">download the source for this service</a> to see what it does, but you have no guarantee that this is actually the code I'm using; you basically have to decide whether to trust me or not. :-) @@ -1067,10 +1066,10 @@ EOHD sub daily_tip { - my @tipAddrs = keys %{$CFG->{'Tips DB'}}; + my @tipAddrs = keys %{$CFG->{Tips_DB}}; srand(time()); my $tipAddr = $tipAddrs[rand scalar @tipAddrs]; - my $tipSlug = $CFG->{'Tips DB'}->{$tipAddr}; + my $tipSlug = $CFG->{Tips_DB}->{$tipAddr}; return <<"EOHD"; <dl class="tip"> @@ -1097,8 +1096,9 @@ sub handle_uri { # Disable checking if the URI is local (or private) for security reasons, # or at least make it configurable to do so. # eg. /^(localhost(\.localdomain)?|127\..+)$/ (+ private networks) + # Net::IP from CPAN could be useful here. # - $ua->protocols_allowed($CFG->{'Allowed Protocols'} || ['http', 'https']); + $ua->protocols_allowed($CFG->{Allowed_Protocols}); unless ($ua->is_protocol_supported($uri)) { $File->{'Error Flagged'} = TRUE; @@ -1206,7 +1206,7 @@ sub parse_content_type { my($ct, @param) = split /\s*;\s*/, lc $Content_Type; - $type = $CFG->{'File Type'}->{$ct} || $ct; + $type = $CFG->{File_Type}->{$ct} || $ct; foreach my $param (@param) { my($p, $v) = split /\s*=\s*/, $param; @@ -1337,7 +1337,7 @@ sub truncate_line { sub override_doctype { no strict 'vars'; my $File = shift; - local $dtd = $CFG->{'Doctypes'}->{$File->{Opt}->{DOCTYPE}}; + local $dtd = $CFG->{Doctypes}->{$File->{Opt}->{DOCTYPE}}; local $HTML = ''; local $seen = FALSE; @@ -1363,7 +1363,7 @@ sub parse_errors ($$) { my $fh = shift; $File->{Errors} = []; # Initialize to an (empty) anonymous array ref. - +warn('@@@-> ' . $CFG->{SGML_Parser}); for (<$fh>) { push @{$File->{'DEBUG'}->{Errors}}, $_; my($err, @errors); @@ -1513,8 +1513,8 @@ EOHD print qq( <li><em>Line <a href="#line-$err->{line}">$err->{line}</a>, column $err->{char}</em>: ); print qq{<span class="msg">$err->{msg}</span>}; - if (defined $CFG->{'Error to URI'}->{$err->{idx}}) { - print qq{ (<a href="$CFG->{'Msg FAQ URI'}#$CFG->{'Error to URI'}->{$err->{idx}}">explain...</a>).}; + if (defined $CFG->{Error_to_URI}->{$err->{idx}}) { + print qq{ (<a href="$CFG->{Msg_FAQ_URI}#$CFG->{Error_to_URI}->{$err->{idx}}">explain...</a>).}; } elsif ($DEBUG) { print qq{ (<code style="background: red">"$err->{idx}"</code>)}; } @@ -1539,7 +1539,7 @@ sub report_valid { unless ($File->{Version} eq 'unknown' or defined $File->{Tentative}) { if ($File->{Version} =~ /^HTML 2\.0$/) { - $image_uri = "$CFG->{'Home Page'}images/vh20"; + $image_uri = "$CFG->{Home_Page}images/vh20"; $alttext = "Valid HTML 2.0!"; $gifborder = ""; } elsif ($File->{Version} =~ /HTML 3\.2</) { @@ -1571,7 +1571,7 @@ sub report_valid { $gifhw = ' height="31" width="88"'; $xhtmlendtag = " /"; } elsif ($File->{Version} =~ /XHTML Basic 1.0/) { - $image_uri = "$CFG->{'Home Page'}/images/vxhtml-basic10"; + $image_uri = "$CFG->{Home_Page}/images/vxhtml-basic10"; $alttext = "Valid XHTML Basic 1.0!"; $gifborder = ""; $gifhw = ' height="31" width="88"'; @@ -1583,16 +1583,16 @@ sub report_valid { $gifhw = ' height="31" width="88"'; $xhtmlendtag = " /"; } elsif ($File->{Version} =~ /HTML 3\.0/) { - $image_uri = "$CFG->{'Home Page'}images/vh30"; + $image_uri = "$CFG->{Home_Page}images/vh30"; $alttext = "Valid HTML 3.0!"; } elsif ($File->{Version} =~ /Netscape/) { - $image_uri = "$CFG->{'Home Page'}images/vhns"; + $image_uri = "$CFG->{Home_Page}images/vhns"; $alttext = "Valid Netscape-HTML!"; } elsif ($File->{Version} =~ /Hotjava/) { - $image_uri = "$CFG->{'Home Page'}images/vhhj"; + $image_uri = "$CFG->{Home_Page}images/vhhj"; $alttext = "Valid Hotjava-HTML!"; } elsif ($File->{Version} =~ /ISO\/IEC 15445:2000/) { - $image_uri = "$CFG->{'Home Page'}images/v15445"; + $image_uri = "$CFG->{Home_Page}images/v15445"; $alttext = "Valid ISO-HTML!"; } @@ -1602,7 +1602,7 @@ sub report_valid { print qq(<h2 id="skip" class="valid">This Page Is Valid!</h2>\n); } - print &daily_tip($File, $CFG->{'Tips DB'}); + print &daily_tip($File, $CFG->{Tips_DB}); &print_warnings($File); print <<".EOF."; @@ -1627,7 +1627,7 @@ sub report_valid { </p> <pre> <p> - <a href="$CFG->{'Home Page'}check/referer"><img$gifborder + <a href="$CFG->{Home_Page}check/referer"><img$gifborder src="$image_uri" alt="$alttext"$gifhw$xhtmlendtag></a> </p> @@ -1644,7 +1644,7 @@ sub report_valid { print qq( <h2 class="valid">This document is well-formed XML.</h2>\n); } elsif (defined $File->{Tentative}) { print qq(<h2 class="valid">This Page <em>Tentatively</em> Validates As $File->{Version} (Tentatively Valid)!</h2>); - print &daily_tip($File, $CFG->{'Tips DB'}); + print &daily_tip($File, $CFG->{Tips_DB}); &print_warnings($File); print <<".EOF."; <p> @@ -1852,7 +1852,7 @@ EOF { my $close = ''; $close = "/" if $1 eq ")"; # ")" -> close-tag "<" . $close . "<a href=\"" . - $CFG->{'Element Ref URI'} . $CFG->{'Element Map'}->{lc($2)} . + $CFG->{Element_Ref_URI} . $CFG->{Element_Map}->{lc($2)} . "\">$2<\/a>>" }egx; $printme =~ s,^A, A,; # indent attributes a bit |