Learn how to add a custom radio field to any USP Form.
Step 1: Use the following code for your Custom Field definition:
field#input_radio|radio_inputs#Option 1:Option 2:Option 3|radio_checked#Option 1|desc#My Label
Step 2: Add the custom-field shortcode to your form, for example:
[usp_custom_field form="123" id="1"]
That’s all there is to it. Here is a screenshot of the radio field we just built:
Note: To see a live example of a custom radio field, check out the “Starter” form demo, included in USP Pro version 2.3 and better (visit USP Forms > “Starter Form Demo”).
Here are the attributes available for custom radio fields:
field– specifies the type of custom field
radio_inputs– list of radio inputs
radio_checked– specifies which radio input should be selected by default
data-required– make the radio field required
desc– adds a description/label to the group of radio inputs