Re: trying to achieve Level Triple-A conformance



On 2009-08-22, William Gill <nospam@xxxxxxxxxxxxxx> wrote:
Jukka K. Korpela wrote:
Validation is a useful tool for those who understand what it is about.
Sadly enough, less than one per cent of authors understand that. But
being positive, we can hope that some others benefit from it as well,
intuitive as it may be (and intuition is mostly something that leads to
mistakes).

Let me take a swing at summarizing for the other 99+ percent.
[...]
To appreciate the benefits of validation, examine the archives of this
NG and look at the impact of the inconsistent visual rendering between
the most prevalent browsers

Those are more often caused by authors not realizing the places where
the specs leave some latitude anyway or by browsers interpreting CSS
rendering differently.

and consider how much greater that impact is
when the source document is itself a random structure (i.e. doesn't
comply with an accepted standard.) Now extend this impact onto a host
of other UI's, visual, non-visual, available today, and yet to be
imagined, and the value of validation becomes more obvious. This is why
when addressing a rendering issue, the users here almost always begin by
insuring the "problem document" be validated.

To put it succinctly, a valid document is not guaranteed to render as
you want, but an invalid one is almost assured not to.

Most invalid documents render fine, because the CSS rendering model is
much more liberal than the HTML DTD.

For example, a common cause of invalidity is mixing up INLINE and BLOCK
things-- just put a div inside a span, or even some text directly inside
a blockquote, and you've got validation errors.

But as far as the CSS renderer is concerned, div and span only differ in
that one is display: block and the other display: inline. CSS specs
define the behaviour of display: block inside display: inline, so they
have to handle that anyway, and most browsers' parsers just let it
straight through. So you just get a div inside a span and it just works,
even though it's invalid.

But, browsers will arbitrarily and unpredictably patch up some but not
all invalid HTML. Some things (links and forms mainly) don't only affect
rendering but also behaviour.

It's also very easy just to fail to close a tag by mistake. So you
should validate because it's easy and rules out a bunch of common
errors. But in a lot of cases it won't actually make any difference,
which explains why impatient commercial types get jaded about it.

Documents are supposed to be valid not just for rendering but also for
search engines and for audio rendering/other processing of the abstract
document. But the former has a whole industry built around it which
decoys the concerns of commercial operations and the latter is mostly a
pipe dream.
.



Relevant Pages