How to Create a Group of Radio Buttons in Shack Forms

In some use cases, you may want to create a group of several radio buttons for your form submitters. For example, you may want your form to ask them what their favorite pet is. 

You would like to create for them a field "Favorite Pet". And you would like this field to give them the following choices of pets:

  • Dogs
  • Cats
  • Parrots
  • Fish
  • Horses.

Creating such a field is a two-step process:

  1. Create a new field by the "Radio group" field type.
  2. Separate the names of the radio buttons by the pipe (|) symbol.

Let's take a look at this process in more detail. 

Step #1. Create a new field by the "Radio group" field type

  • In your Joomla administrator panel, go to Extensions > Modules.
  • You will be taken to the "Modules (Site)" administrative page. Locate here you Shack Forms module and click on its title.
  • You will see the "Modules: [Your Shack Forms module name]" page. Under the "Module" tab, click the blue "Add new field" button:

click add new field

  • Enter "Favorite Pet" into the "Field label" field:

enter favorite pet into the field label field

  • Find the "Field type" field and click "Text":

find the field type field and click text

  • In the drop-down list of your Shack Form field types, click "Radio group":

click radio group

Step #2. Separate the names of the radio buttons with the pipe (|) symbol

  • Find the "Values" field and enter in it your list items, separated by the pipe (|) symbol. As we decided earlier, I entered "Dogs|Cats|Parrots|Fish|Horses":

enter pets name separated by the pipe symbol

  • Click "Save" or "Save & Close".
  • Check the form at the frontend of your site. You will see that your form submitter can now see the "Favorite Pet" group of radio buttons and select their pet:

final result