IIRC though, while RFC 1866 says "exactly one" the checked attribute
is optional in W3C guidelines.

HTML 4.01 (and thus also the XHTML 1 series) state:
[http://www.w3.org/TR/html4/interact/forms.html#radio]
<<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.>>

So if you leave them both undefined, some UAs will select the first,
some will select neither.  I can't see many doing anything else.  It's
not standards aversion and I can't see why that's not ok.  HTML4.01
spec goes on to say that authors should ensure one is selected by
default but I'm not sure why you need consistant behavior in this
case.

If worst comes to worst, just have whichever one comes first in the
page checked="checked".  You'll be "inconveniancing" roughly half the
people no matter which is checked by default.  If neither are then
it's the same "inconvenience" for everyone.

I guess I'm saying that I'd consider this a moot point - check
whichever you'd like and the user will deal with it.

Regards,

mjec


On Wed, 2 Feb 2005 08:54:31 +1100, Wybrow, Mark
<[EMAIL PROTECTED]> wrote:
>  
> Or pass hidden parameters onto the action page ... these then can be over
> ridden if the radio is selected
>  
>  
>  ________________________________
>  From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On
> Behalf Of Mike Kear
> Sent: Wednesday, 2 February 2005 2:51 AM
> To: wsg@webstandardsgroup.org
> Subject: RE: [WSG] Default state of radio buttons. (Maybe OT?)
> 
>  
> With radio buttons, no value is passed to the form's action page unless one
> of the options is selected.   This will normally cause an error in the
> processing page unless special consideration is given to this possibility.
> 
> Normally if there are radio buttons on the form, it is best to ensure that
> at least one option is selected. 
> 
> Cheers
> Mike Kear
> AFP Webworks Pty Ltd
> Windsor, NSW, Australia
> http://afpwebworks.com
> Industrial strength coldfusion, .asp, .asp.net, php hosting from A$15/month
>  
>  
> --------- Original Message --------
> From: wsg@webstandardsgroup.org
> To: "wsg@webstandardsgroup.org" <wsg@webstandardsgroup.org>
> Subject: RE: [WSG] Default state of radio buttons. (Maybe OT?)
> Date: 01/02/05 20:56
> 
> 
> I think this is like FAQs - my FAQ is never there. Likewise, pre-set a
> control
> to option A and I'm equally likely to want option B.
> 
> IMHO pre-setting options for the user (unless they're VERY obvious) is like
> making assumptions about them.
> 
> That said, RFC1866 says 'CHECKED' is optional but then says "At all times,
> exactly one of the radio buttons in a set is checked. 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."
> 
> Does anybody know why one button has to be checked "at all times" in a
> circumstance like Chris referred to?
> 
> Thanks
> Rowan
> 
> 
> 
> Quoting Iain Gardiner <[EMAIL PROTECTED]>:
> 
> > Oops, sorry I didn't really read your question thoroughly. Surely an
> > e-mail
> > address will be either a personal or a business address. Personally I'd
> > set
> > the default to personal as this seems to me the most likely option.
> >
> > Iain
> >
> > ------------------
> > Iain Gardiner
> > http://www.firelightning.com
> >
> >
> > -----Original Message-----
> > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On
> > Behalf Of Chris W. Parker
> > Sent: 01 February 2005 19:12
> > To: wsg@webstandardsgroup.org
> > Subject: [WSG] Default state of radio buttons. (Maybe OT?)
> >
> >
> > Hello,
> >
> > Not sure if this is off topic or not, but let me know if it is.
> >
> > I'm wondering what the suggested default state of a group of radio
> > buttons
> > is? Let me use a current, specific example.
> >
> > In a form I'm writing I have one set of radio buttons. The current
> > options
> > are 'Home', or 'Agency'. The radio button is meant to designate what
> > type of
> > mailing address the customer has provided. Right now I've got neither
> > option
> > being defaulted to. I know that radio buttons should have exactly one
> > option
> > chosen at all times, but in this case it doesn't make sense to add a
> > third
> > option of 'None', or have the group default to one option or the other.
> >
> > How should I handle this? Should I bite the bullet and have the options
> > default to one of the options (both options will probably be chosen an
> > equal
> > amount of times, as has been the case in the past)? Or maybe I should go
> > to
> > a drop down list with three options? 1. '-', 2. 'Home', 3. 'Agency'
> >
> >
> > Your feedback is appreciated.
> >
> > Chris.
> > ************************************************ ******
> > The discussion list for http://webstandardsgroup.org/
> >
> > See http://webstandardsgroup.org/mail/guidelines.cfm
> > for some hints on posting to the list & getting help
> > ******************************************************
> >
> >
> > ****** ************************************************
> > The discussion list for http://webstandardsgroup.org/
> >
> > See http://webstandardsgroup.org/mail/guidelines.cfm
> > for some hints on posting to the list & getting help
> > ******************************************************
> >
> >
> 
> 
> 
> ******************************************************
> The discussion list for http://webstandardsgroup.org/
> 
> See http://webstandardsgroup.org/mail/guidelines.cfm
> for some hints on posting to the list & getting help
> ******************************************************
> 
> 
> 
> 
> 
> 
> 
> ________________________________________________
> Message sent using UebiMiau 2.7.2
> ****************************************************** The discussion list
> for http://webstandardsgroup.org/ See
> http://webstandardsgroup.org/mail/guidelines.cfm for some hints on posting
> to the list & getting help
> ****************************************************** 


-- 
http://mine.mjec.net/
******************************************************
The discussion list for  http://webstandardsgroup.org/

 See http://webstandardsgroup.org/mail/guidelines.cfm
 for some hints on posting to the list & getting help
******************************************************

Reply via email to