Re: Unresolvable error messages?


On Apr 24, 2007, at 00:00 , H. Hahn wrote:
> Validating
> L.S.,
> While trying to validate the abovementioned website, I managed to  
> get rid of most of the errors and warnings reported. However, three  
> errors seem to be unresolvable (see attached PDF file for a listing  
> of both the errors and the source from the website's home page).
> The first error is about a disallowed character string. Actually it  
> is the <meta>-tag defining the character set. This tag is  
> automatically insered by the content management system (TYPO3  
> version 4.0.5). (I need to use UTF-8, as the site may in the (near)  
> future contain some Hebrew text.)

Your CMS is adding an xhtml-style markup in your HTML 4.01 Document.
I'm afraid you would either have to find a configuration for your CMS  
to output proper HTML syntax, or switch your whole document to XHTML.

> The other two errors complain that <head> and <body> are not open  
> at the point where </head> and </body> respectively are found;  
> while both are not true.

These are cascading errors, yes.

> Also, I copied & pasted the entire View Source from Firefox into  
> the validator's "direct input" box, so that I could remove the "/"  
> from the charset meta-tag before validating, but this did not  
> change anything.

Are you *sure*?

> Is there a way to force the validator to overlook certain thnigs  
> (e.g. like lint programmes can suppress dertain types of errors or  
> error groups)? (I am aware that this is contrary to the entire idea  
> of validation, but it may help in the development process.)

No, and I don't know if that would be a good thing.

> A statement like
>      Text = Text.replace (/</g, "[");
> produces an error message "End tag for element <g> which is not open".

I believe this is covered by:

> Somewhere I seem to have read that the W3C validator is based on  
> the Tidy programme

No, Tidy and the validator are based on completely different  
However, the latest validator (currently in beta test [1]) has an  
option to automatically clean up the markup with Tidy:

[ skipping question 4, I'm not sure it is relevant to this list ]

> As I see it, a validator's parser should do the same as (only much  
> more strictly than) a browser's parser, i.e. it should "integrate"  
> everything revelant (like styles, strings, etc.) and of course skip  
> all comments (i,e, BOTH HTML comments and scripting comments).  
> Sctipts should be run as far as they seem relevant for the HTML  
> being generated (although this may nit always be possible).

Browser parsers are built to gracefully deal with pathological  
markup, whereas the validator is here to compare  the markup used  
with well-defined rules. So one has to be careful about saying that  
they're pretty much the same thing. That said, the idea of adding a  
javascript engine to the validator has been suggested before, and it  
could indeed be a good idea, albeit not easy to implement.


Received on Wednesday, 25 April 2007 01:49:19 UTC