On Thu, May 23, 2002 at 05:22:28PM -0400, Michael Marrotte wrote:
> I want an item selected...  I just don't want it selected like that,
> i.e.  selected="selected".  I don't understand why it's generated
> this way.  Why not just selected?

It's for XHTML compliance.  SGML (and HTML) supports (as you know)
attributes with no value, but XML (and XHTML) requires a value
enclosed in double quotes for every attribute of a tag.  Also, XML is
supposed to be case-sensitive, and they chose all-lowercase tags and
attributes.

The XTML spec says to use, e.g. selected="selected" or
noshade="noshade" for an XHTML attribute where the old HTML attribute
had an implied value of "true" whenever the attribute was present.
They presumably tested a bunch of browsers to make sure this was
backward-compatible before recommending it. :)

See <http://www.w3.org/TR/xhtml1/#h-4.5> for the actual recommendation.

-- 
Jonathan Fuerth - SQL Power Group Inc.
(416)218-5551 (Toronto); 1-866-SQL-POWR (Toll-Free)
Unleash the Power of your Corporate Data - http://www.sqlpower.ca/

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to