W3C home > Mailing lists > Public > www-validator@w3.org > February 2004

Re: XHTML Validation using Apache Ant

From: Beton, Richard <richard.beton@roke.co.uk>
Date: Mon, 16 Feb 2004 17:29:40 +0000
To: www-validator@w3.org
Message-ID: <4030FE04.9080003@roke.co.uk>
Bjoern Hoehrmann wrote:

>Use
>
>  * http://www.w3.org/TR/xhtml11/xhtml11.zip or
>  * http://www.w3.org/TR/xhtml11/xhtml11.tgz
>
>Or reference
>
>  * http://www.w3.org/TR/xhtml11/DTD/xhtml11-flat.dtd
>  
>


Excellent, that's a great improvement.  I have attached my successful 
Ant validation scripts.  There are three files:

* validate.xml is the Ant buildfile and provides the main guts.

* xmlcatalog.xml is a catalog giving the local cache filenames of the 
DTDs (having this is most important in achieving reasonable validation 
times).  Only the W3C entries are of general interest; you can delete 
the first three entries, which are specific to my website.

* validate-html.bat is my start script.  Validation can start at the 
document root ('htdocs') or any sub-tree within it.  Note that it 
depends on some Cygwin unix-like tools, grep and tail.

I validated 1626 XHTML files in my website in just under three minutes 
on a 2.4GHz PC.

Would anyone care to comment on whether it is preferable to use Ant or 
to download and use the offline W3C validator? And why?  The only issue 
I can think of is that the Ant approach doesn't work for legacy HTML, 
which I have now moved away from.  Can anyone suggest other pros and cons?

Rick :-)







-- 
Registered Office: Roke Manor Research Ltd, Siemens House, Oldbury, Bracknell,
Berkshire. RG12 8FZ

The information contained in this e-mail and any attachments is confidential to
Roke Manor Research Ltd and must not be passed to any third party without
permission. This communication is for information only and shall not create or
change any contractual relationship.



Received on Monday, 16 February 2004 12:32:06 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Wednesday, 25 April 2012 12:14:10 GMT