Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

We've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

Form Questions /

Moderators: martimiz, Sean, Ed, biapar, Willr, Ingo, swaiba

Individual radio buttons?


Go to End


2 Posts   1641 Views

Avatar
Bennett

Community Member, 2 Posts

21 February 2014 at 9:50am

How can you have radio buttons in the same group but separated on the form? For example below, the two radio buttons (Existing User and New User) are part of the same group, but have other fields between them. I believe OptionsetField always displays the radio buttons together, so I can't use that. What can I use?

O Existing User

User ID: [_______]

O New User

Name: [_______]
Password: [_______]

Avatar
Willr

Forum Moderator, 5523 Posts

21 February 2014 at 9:32pm

I do believe SelectionGroup implements this functionality http://api.silverstripe.org/3.1/class-SelectionGroup.html