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

Re: Errors in non-existing elements

From: Boris 'pi' Piwinger <3.14@logic.univie.ac.at>
Date: Thu, 11 Mar 2004 15:17:24 +0100
Message-ID: <405074F4.1000403@logic.univie.ac.at>
To: www-validator@w3.org

Nick Kew wrote:

>> To give an example: Say you have a web page using embed
>> which does not exist in HTML 4. Now there will be a lot of
>> attributes to the embed tag. The validator complains about
>> each of them. This is useless, it only hides the real error
>> and hence makes the output hard to read.
> That's an artifact of how the underlying parser works.  It runs
> straight through.
> So, given:
> <foo bar="nonsense" other="rubbish"  >
>                   1               2  3
> it finds and reports attribute errors at 1 and 2, 

To do that it will need to verify what the legal attributes
to foo are (and hence notice that foo is not a legal element).

> but the <foo> tag
> isn't closed until 3, so it doesn't get checked 

From above I assume it is checked indirectly.

So the solution would be (if my above diagnosis is correct)
to not output wrong attributes if the element doesn't exist.

Received on Thursday, 11 March 2004 09:17:43 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 1 March 2016 14:17:40 UTC