Re: Validator complains about <nobr>

On Wed, 23 Aug 2006, olivier Thereaux wrote:

> Hello Jukka,
>
> On Aug 23, 2006, at 01:31 , Jukka K. Korpela wrote:
>> If you wish to use <nobr> and still use a validator, you might consider 
>> using a validator that can deal with "extended DTDs"
>
> While this is technically correct, I really don't think it's a good idea to 
> be suggesting using extended DTDs.

An "extended DTD" needs to be used _if_ one wishes to use <nobr> and still 
use a validator. I use the quotes to indicate that it's a matter of 
extended DTD only in a relative sense. You can use an SGML or XML 
validator to check the syntax of any document that has a DTD, even a DTD 
you soup up from scratch.

> You know what tweaking DTDs involve and 
> imply, whereas I suspect most of the people using proprietary markup:
> - don't know (and don't really want to know) how to extend a DTD

That's why I referred to some existing "extended DTDs".

> - don't know what are the benefits and risks of doing so.

Well, most people who use validators don't know what validation is, and I 
don't think using an extended DTD will add to the confusion. People make 
the crucial decision when they decide to use some element or attribute. 
Validation will merely help them check whether they have used it according 
to some syntax rules. (Personally, I often mistype </nobr> as </nibr> or 
something, or even as <nobr>. I surely want to catch such errors.)

> I think it's better to teach 
> people a bit of CSS to replace their proprietary markup than explain about 
> extending DTDs for the purpose of getting a green validation banner...

As you hopefully know, I have never taught people to do anything to get 
a green validation banner, still less to get the "right" to use a
validation icon. The purpose of validation should be to find syntax 
errors, nothing more, nothing less.

Using CSS vs. nonstandard markup is a design issue. If someone decides to 
use <nobr>foo-bar</nobr> (instead of e.g. <span style="white-space: 
nowrap">foo-bar</span>), it then becomes a validation issue. Surely 
someone who decides to use an "extended DTD" to find out that he has used 
the <nobr> markup as he intended (and to find error messages relating to 
other aspects of markup more conveniently when they are not interspersed 
with messages about <nobr>), he will be reducing risks, not taking any 
additional risks. The risks, if any, are included in the decision to use 
<nobr> in the first place.

-- 
Jukka "Yucca" Korpela, http://www.cs.tut.fi/~jkorpela/

Received on Friday, 25 August 2006 07:32:56 UTC