I have a multiple select box:
<select name="tar[]" multiple="multiple" style="height:100px;" id="select1">
<?php foreach($lists as $list){ ?>
<option value="<?php echo $list['des_id']; ?>"><?php echo $list['designation']; ?></option>
<?php } ?>
</select>
At controller i am trying to get the values of selected fields,but failed to get that and i am getting values like 2 or 3.
$target = $this->input->post('tar');
print_r($target);die;
Am i doing right??please guide me.Thanks.
okay i got the answer…
here is i am wrong,just i have to define the array in controller: