• Hello Fabrik Community

    Fabrik is now in the hands of the development team that brought you Fabrik for Joomla 4. We have recently transitioned the Fabrik site over to a new server and are busy trying to clean it up. We have upgraded the site to Joomla 4 and are running the latest version of Fabrik 4. We have also upgraded the Xenforo forum software to the latest version. Many of the widgets you might have been used to on the forum are no longer operational, many abandoned by the developers. We hope to bring back some of the important ones as we have time.

    Exciting times to be sure.

    The Fabrik 4.0 Official release is now available. In addition, the Fabrik codebase is now available in a public repository. See the notices about these in the announcements section

    We wish to shout out a very big Thank You to all of you who have made donations. They have really helped. But we can always use more...wink..wink..

    Also a big Thank You to those of you who have been assisting others in the forum. This takes a very big burden off of us as we work on bugs, the website and the future of Fabrik.

Radio Button element

  • Views Views: 15,156
  • Last updated Last updated:

Navigation

      Access element (+)
      Birthday element
      Button element
      Calculation element
      Captcha element
      Checkbox element
      Colour Picker element
      Count element (+)
      Database join element
      Date element
      Digg element
      Display text element
      Dropdown element
      Facebook Like element
      Field element
      File Upload element
      Folder element
      Google Map element
      Image element
         Image databese join
      Internal id element
      IP element
      J!Date element
      Kaltura element
      Link element
      Notes element
      OpenStreetMap element
      Picklist element
      Radio Button element
      Rating element
      Sequence element
      Slider element
      Tags element
      Textarea element
      Thumbs element
      Time element
      Timer element
      Timestamp element
      Total element
      User element
      User group element
      Video element
      View level element
      YesNo element
      Youtube element
      Akismet validation
      Is Email validation
      Is Not validation
      Is Numeric validation
      Not empty validation
      PHP validation
      Rsa id
  • Introduction​


    Renders a a series of radio input Options.

    Details Tab​

    Options​


    Capture.JPG

    • Sub Options - The list of Options for the radio buttons. Use the green + to add more, the red - to remove Options and the grey boxes on the right to drag and drop to change the order.
      NOTE: Options can be programmatically added to this list Using eval Populate on the Advanced tab.
      • Value - The value that is stored in the database if the drop down option is selected.
      • Label - The label that appears next to the drop down option. Equally this label is shown in the table view rather than the recorded value (which is stored in the database table itself)
      • Default - is the option selected as default
    • Options per row - Specify the number of columns used to render the radio buttons. A smaller number will place the Options FARTHER apart. If you have short Options, then choosing a number like 8 would help move the Options closer together without as much whitespace between them.
    • Button group - Renders the Options as a Bootstrap 'button group' vs. the traditional html radio buttons (a button group is similar to the No/Yes choice of button group).
      BUTTON GROUP NOTES:
      • Button Groups work only on Joomla 3 (with Bootstrap)
      • If you use Javascript events, you have to use a click event (and not the change event).

    Front End Addition​

    • Allow user to add drop down option - Allow your form's users to add in additional Options to your form.
    • Only add label - If no selected then the user has to enter both a value and a label for the checkbox option they are adding. If yes selected then only a label field is presented to the user the value of which is then used for the value and label.
    • Save new additions - If yes selected then the newly submitted option is stored by the element, meaning subsequent users of the form will be able to select the same value.

    Advanced Options​

    • Eval Populate - PHP that can generate a list of Options to add to list added using JHTML.
      See also the dropdown element
    • For example, here is some code that will build a list of years from the current year and the previous 10 years.
      PHP:
      for ($year = date('Y'); $year > date('Y', strtotime('-10 years')); $year--) {
      $options[] = JHTML::_('select.option',$year,$year); }
      return $options;
    • Note: There is no way to specify a default selected option using this method.

    Additional data​


    Sometimes, when editing a record, you may see sub-options appearing that are not listed in the element's admin page. This is because the current record has values that are not found in the sub-options. This could occur because:
    • Data was entered manually into the database
    • Data previously entered from a radio sub option that has been subsequently deleted
    • The user has been allowed (possibly at some point) to add their own options but not set to store that added option as a option available to other users.
    With Fabrik we work on the principle of trying to be as lenient as possible with the data stored/displayed. If someone has entered it in, we will try to to produce processes where it will be not removed.
Back
Top