Welcome Guest, Not a member yet? Register   Sign In
How to Keep maintain Radio button and chekbox Values After submit in form
#5

(05-06-2015, 08:22 AM)mwhitney Wrote: On your call to form_dropdown(), you're passing "-1" to the $selected parameter. If you pass the selected value (or an array of selected values if it supports multiple selections), it will select that value. If you don't pass a value to this parameter (or pass an empty array), it will attempt to automatically detect the selected value.

For each of your form_checkbox() calls, you should pass a third parameter, which should be set to true when that checkbox is checked, and false when it is not.

For radio buttons, form_radio() just sets the type to 'radio', then passes the parameters through to form_checkbox(), so they should be treated similarly to the checkboxes.

I am not like to give a by default values ... Whether user select on radio button that only selected... otherwise show error message like plz check one  ...  if employee is selected one radio button .. after submit  how to keep that value in radio buttons... ?  
Manikanta
Reply


Messages In This Thread
RE: How to Keep maintain Radio button and chekbox Values After submit in form - by Chandini - 05-06-2015, 10:40 PM



Theme © iAndrew 2016 - Forum software by © MyBB