We use cookies to improve your experience. No personal information is gathered and we don't serve ads. Cookies Policy.

ExpressionEngine Logo ExpressionEngine
Features Pricing Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University
Log In or Sign Up
Log In Sign Up
ExpressionEngine Logo
Features Pro new Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University Blog
  • Home
  • Forums

inline_radio not working

Developer Preview

Reinos's avatar
Reinos
79 posts
7 years ago
Reinos's avatar Reinos

It looks like the inline_radio does not respect the selected value in case the values are ‘0’ or ‘1’. When the value is a word like ‘test ’ it is working.

See the example below.

$vars['sections'] = array(
   array(
    array(
     'title' =>'_report_stats',
     'desc' => 'PHP & EE versions will be anonymously reported to help improve the product.',
     'fields' => array(
      'report_stats' => array(
       'type' => 'inline_radio',
       'value' => '0',
       'choices' => array(
        '1' => 'Yes',
        '0' => 'No'
       )
      )
     )
    ),
              
   )
  );

  // Final view variables we need to render the form
  $vars += array(
   'base_url' => ee('CP/URL', 'cp/addons/settings/form'), //<-- load a template with this content: <?php $this->embed('ee:_shared/form')?> and some other html
   'cp_page_title' => lang('general_settings'),
   'save_btn_text' => 'btn_save_settings',
   'save_btn_text_working' => 'btn_saving',
   'alerts_name' => GMAPS_DATA_MAP.'_settings'
  );

  return $this->output('form', $vars, 'settings');
       
Kevin Cupp's avatar
Kevin Cupp
791 posts
7 years ago
Kevin Cupp's avatar Kevin Cupp

Yes looks like that’s the case, sorry about that! We’ll have a fix in the next release.

       
Reinos's avatar
Reinos
79 posts
7 years ago
Reinos's avatar Reinos

Ok thanks!

       

Reply

Sign In To Reply

ExpressionEngine Home Features Pro Contact Version Support
Learn Docs University Forums
Resources Support Add-Ons Partners Blog
Privacy Terms Trademark Use License

Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.