t; -Original Message-
> From: Michael Sweeney [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, January 22, 2003 10:29 AM
> To: Ben C.
> Cc: [EMAIL PROTECTED]
> Subject: Re: [PHP] Select value for driopdown box
>
>
> Assuming that you know which state is selected b
I tried to use the below but it does not work. Please help!
-Original Message-
From: Michael Sweeney [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, January 22, 2003 10:29 AM
To: Ben C.
Cc: [EMAIL PROTECTED]
Subject: Re: [PHP] Select value for driopdown box
Assuming that you know which
lue pair that has the value that you are looking
for as the key and if it matches it will make that key - value assoc the
selected one.
that should work for you
- Original Message -
From: "Ben C." <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, January 22,
Assuming that you know which state is selected before you build the
select list:
$sel_state = $_REQUEST['state'];
...
while($row = mysql_fetch_array($result)) {
$buyerid = $row['buyerid'];
$state = $row['state'];
$selected = $state == $sel_state ? "selected=\"selected\"" : "";
$
I am using the query below to edit a record. I want to edit the field which has a list
of states in a dropdown box. I want to have the state that is in the selected field
shown as the selected state. How would I do this?
Query
-
$state";
}
$display_block = "
$optio
5 matches
Mail list logo