CodeIgniter Forums
getting the selected value in a dropdown list - 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: getting the selected value in a dropdown list (/showthread.php?tid=19001)



getting the selected value in a dropdown list - El Forum - 05-24-2009

[eluser]Unknown[/eluser]
In my view form, I have a dropdown list with values.

I want to pass the selected value of the user to the controller.

form_input() have this in the controller:

$this->input->post('name');

is there a counterpart for the form_dropdown() , wherein it can access the selected value from the view file?


getting the selected value in a dropdown list - El Forum - 05-24-2009

[eluser]Thorpe Obazee[/eluser]
It uses the same method, $this->input->post('field_name')