ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

Safecracker radio buttons with zero value

November 12, 2012 12:41am

Subscribe [2]
  • #1 / Nov 12, 2012 12:41am

    superbiaweb

    26 posts

    Hi,

    I have a radio button fieldtype with the values 0 - 10. It outputs fine in my Safecracker form with the {field:my_field_name} tag. However when I try to use the {options:my_field_name} tag pair to customise the markup, the zero value is removed from the radio button group. It doesn’t matter what order the values are presented when setting up the fieldtype, the zero value is always removed. Here’s the code I’m trying to use:

    {options:my_field_name}
        <label><input name="{option_name}" value="{option_value}" type="radio"{checked}> {option_value}</label> 
    {/options:my_field_name}

    Thanks,

    Dylan

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases