CodeIgniter Forums
form_dropdown undocumented behavior - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23)
+--- Thread: form_dropdown undocumented behavior (/showthread.php?tid=40198)



form_dropdown undocumented behavior - El Forum - 04-01-2011

[eluser]blasto333[/eluser]
Code:
<?php echo form_dropdown('payment_type',$payment_options,array(), 'id="payment_types"');?>

If you pass to the third parameter an empty array, code ignitor will look in $_POST for a key of 'payment_type' to determine the selected value. This should be documented.