|
Posted by NC on 07/20/07 23:22
On Jul 20, 4:07 pm, "Larry L [in Honolulu]" <la...@no-place.org>
wrote:
>
> I have a dropdown list dynamically created in a form
> by PHP from a MySql table. This is the only element
> on the page. For some records there is only a single
> selection, and if that's the case I'd like to just
> post that and go to the next page. Is there a simple
> way to do that using POST?
Yes, but it's got nothing to do with PHP:
<form method="POST" action="[your_action_goes_here]">
<select name="mySelect" id="mySelect"
onChange="mySelect.form.submit()">
<option value="">Select an option
<option value="1">Option 1
<option value="2">Option 2
<option value="3">Option 3
<option value="4">Option 4
</select>
</form>
Cheers,
NC
Navigation:
[Reply to this message]
|