Re: Report page in validation service is not well-formed XML when the validation was successful

Hi Lars,

On 28-May-08, at 7:25 AM, Svensson, Lars wrote:
> The validation results page in the css-validator returns not well- 
> formed XML when the validation was successful. When the validation  
> wasn't successful, the returned document is well-formed. First I  
> tried this with file upload and then with validation per URL, always  
> with the same result.
> Interestingly enough, the page validates in the HTML validator, but  
> it's obvious that the XML is invalid. The problem is in line 35,  
> where there is a closing </a> tag within the <p> element but no  
> opening <a>.

This was fixed a few weeks ago in the development version of the  
validator.
http://dev.w3.org/cvsweb/2002/css-validator/org/w3c/css/css/xhtml.properties.diff?r1=1.16&r2=1.17&f=h

Yves, let's put this into production independently of (and before) the  
grammar changes?


> The background is that I wanted to build a validation script, upload  
> the file(s) per URL and then check for the existence of a <div  
> id="errors">. To do this, I parse the result page with an XML parser  
> (it's supposed to be XHTML) and check for the div using an Xpath.

If you're going to parse validation results as XML, I would strongly  
recommend, instead of screen-scraping the HTML output, to use:
http://jigsaw.w3.org/css-validator/api.html

regards,
-- 
olivier

Received on Thursday, 29 May 2008 17:04:24 UTC