Can I make a fieldset required in a form?

Anonymous
Not applicable

Can I make a fieldset required in a form?

Is it possible to make a fieldset required? That is, I know I can make each field within a fieldset required, but to do so requires making every field required. I would like to make it so that at least one of the fields is selected before the person can go on and click the Submit button.

Thanks in advance for your help!

Laura

3 REPLIES 3
SanfordWhiteman
Level 10 - Community Moderator

Re: Can I make a fieldset required in a form?

The answer is Yes, but before I tell you how to do it, are you sure a fieldset is really what you want?  Semantically, a fieldset should hold related fields, but it's sort of like a form within a form.  The fields aren't necessarily interdependent.  Maybe you actually want a radio button set or checkbox set?

Anonymous
Not applicable

Re: Can I make a fieldset required in a form?

I am actually not sure that I want a fieldset...I tried to set the fields as radio buttons, but it seemed like I wasn't getting anywhere. To create a radio button set or checkbox set, does this require an overarching field and then fields within that? Here is the form that I'm working on. Or do I take one field and then create the values within that? I'm just a little lost on what the best approach would be...Thanks.

subscription center pic.JPGsubscription center pic2.JPG

SanfordWhiteman
Level 10 - Community Moderator

Re: Can I make a fieldset required in a form?

This could be done w/3 fields:

  1. Subscription Status. Required.  Single-valued.  Values 'Daily', 'Weekly', or 'None'.  This should be a radio button set, b/c radio buttons automatically make it clear that only one current value is allowed.
  2. Unsubscribe Reason. Optional. Shown if Subscription Status = 'None'.  Multi-valued.Values 'Too many emails','Content not relevant,' etc.  This can be a set of checkboxes.
  3. Unsubscribe Comment. Optional.  Shown if Unsubscribe Reason = 'Other'.  Textbox.