Select validation

10 views
Skip to first unread message

Adnan Džaferović

unread,
Jan 27, 2012, 6:51:58 AM1/27/12
to rainframework

Hi,

I have something like this:

$this->form_obj->add_item('select', 'hear', 'some text', null, null,
'required', array('options'=>$finde_us));

How to setup a require field in this statment, so my first output need
to be

<option value="">Select...</option>

Thank you

Federico Ulfo

unread,
Jan 27, 2012, 7:32:14 AM1/27/12
to rainfr...@googlegroups.com
Hey Adnan,

set the $validation as "required" as you did should work, if doesn't I suggests you to give a look to the validation plugins:

if you have any limitation in your PHP code you can add some javascript to make it works. Please let me know if you make it work.
Thanks
Reply all
Reply to author
Forward
0 new messages