Re: Dynamically created dropdowns
| From: | Michael Hall | Date: | Tue, 04 Dec 2001 20:19:11 +0000 |
| Subject: | Re: Dynamically created dropdowns | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-76489@lists.php.net to get a copy of this message | ||
You can certainly do what you want in straight PHP if you include a form
submission after selecting the manufacturer. There is probably a way of
doing it in JavaScript without a form submission, but not one that will
read data from a MySQL database on a remote machine. JavaScript can't do
that.
Michael
On Tue, 4 Dec 2001, Michael Egan wrote:
> Hope this isn't an inappropriate message to send to this list. I suspect
> the response will largely concern JavaScript.
>
> Is there a way of altering the contents of one drop down menu according
> to the item selected in another?
>
> I'm creating a page allowing users to identify the make and model of
> computers received by our charity for refurbishment. Ideally I'd like to
> allow them to select a manufacturer from a drop down menu and for a
> separate drop down menu to then be populated by the models produced by
> that manufacturer.
>
> I have two separate tables in a MySQL database, one for manufacturers
> and one for models with the latter containing a field for the
> manufacturer ID.
>
> Is this possible?
>
> Michael Egan
>
>
--
################################
Michael Hall
admin@openlearningcommunity.org
m.hall@latis.net.au
http://openlearningcommunity.org