|
Posted by The Natural Philosopher on 10/20/07 10:38
Kye wrote:
>> Have a page which takes the value in $_POST['dropdown'] and performs
>> another SQL query of the desired results.
>>
>> It may be this page (i.e. if $_POST['dropdown'] is set, or a different
>> page, depending on your needs.
>
> Is it possible to make the select element of the form automatically execute
> the "<INPUT type='submit' value='Go'>"; statement rather than having a
> button to click on???
>
Yes, with javascript.
However there are caveats.
If you actually do CHANGE the value displayed, then this code
<SELECT ...onchange="document.forms[0].submit()" >
will submit the form.
if there is only one <OPTION> element IN the select statement, this
doesn't work however. I have a workaround but its ugly.
Navigation:
[Reply to this message]
|