Re: why, e.g., input/@checked="checked" ?

* Robert Koberg wrote:
>I generate XHTML/JSP/Velocity pages from XSL and XML. One thing always 
>seems clumsy to me: that is, why was something like an INPUT's checked 
>attribute be set to "checked" and not true/false?

You can write SGML declarations such that for enumerated attribute
values only the value must be specified so you can write

  <input ... checked> rather than
  <input ... checked="checked">

Using true/false as in

  <input ... true>

would look a bit odd, is more likely to clash with some other attribute
value and is more difficult to extend ("true", "false" and some third
value in the same value space is a bit odd, too).
-- 
Björn Höhrmann · mailto:bjoern@hoehrmann.de · http://bjoern.hoehrmann.de
Weinh. Str. 22 · Telefon: +49(0)621/4309674 · http://www.bjoernsworld.de
68309 Mannheim · PGP Pub. KeyID: 0xA4357E78 · http://www.websitedev.de/ 

Received on Saturday, 26 March 2005 15:05:23 UTC