[thelist] clear form code

Matt Warden mwarden at gmail.com
Mon Mar 20 20:04:34 CST 2006


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

M. Seyon wrote:
> Bottom line though, the current spec does not definitively state that radio 
> buttons must have one button with a default ON state. Rather, it goes out 
> of its way to mention that this is not always the case:
> 
> If no radio button in a set sharing the same control name is initially "on"...

That's an interesting interpretation, probably resulting from only
reading the first part of the sentence. The sentence actually reads:

"If no radio button in a set sharing the same control name is initially
"on", user agent behavior for choosing which control is initially "on"
is undefined."

Again, this is describing an error condition. The way I read it, it very
clearly implies that there is always an initial "on" radio button. If it
is not specified with the required checked='true' attribute, then the
user agent is expected to choose an initial "on" radio button. It is
this algorithm that is undefined.

You are right that the spec distances itself from the language used in
the html2 rfc, but this is only because the strength of the user agent
recommendation is no longer appropriate:

"If none of the <INPUT> elements of a set of radio buttons specifies
`CHECKED', then the user agent must check the first radio button of the
set initially."

There are user agents which do not check the first radio button of the
set initially when there is no explicitly checked button. Since this is
the case, the current spec instead says the initial-checking algorithm
is undefined (rather than always the first in the set).

> Then why doesn't the spec come out and say "Thou shalt not have
> no radio  buttons selected"

How about something like:

"authors should ensure that in each set of radio buttons that one is
initially "on"."
(http://www.w3.org/TR/REC-html40/interact/forms.html#radio)

No "thou", but close enough.

- --
Matt Warden
Miami University
Oxford, OH, USA
http://mattwarden.com


This email proudly and graciously contributes to entropy.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iD8DBQFEH18yrI3LObhzHRMRAlxLAJ9N6dmzSUlNd2YhXWVrL81vz+CRwACfark/
xdIxg9EfhaVlPo0wzIKtztI=
=eq+K
-----END PGP SIGNATURE-----



More information about the thelist mailing list