Welcome Guest, Not a member yet? Register   Sign In
HTML Select Problem
#1

[eluser]eric cumbee[/eluser]
i have several HTML Select dropdowns on the same page, used in slightly different contexts. they both use the same option data that is stored and echoed out of a php variable that was built from a database query.

The Problem i am running into is that one works and returns the selected value, while the other one only returns the value of the first option.

this is my markup for the one that works

Code:
<select name="Home_State" id="Home_State"/>
                &lt;?php echo $states;?&gt;
                </select>
This is my markup for the one that does not work

Code:
<select name="Mail_State" id="Mail_State">
                         &lt;?php echo $states;?&gt;
                    </select>
and then getting the form value using CI
Code:
$Mail_State = $this->input->post('Mail_State');
echo $Mail_State;
returns the value of the first option regardless of what option is selected.


Messages In This Thread
HTML Select Problem - by El Forum - 11-04-2009, 04:15 PM
HTML Select Problem - by El Forum - 11-04-2009, 04:43 PM
HTML Select Problem - by El Forum - 11-04-2009, 06:30 PM
HTML Select Problem - by El Forum - 11-04-2009, 06:50 PM
HTML Select Problem - by El Forum - 11-04-2009, 06:55 PM



Theme © iAndrew 2016 - Forum software by © MyBB