forms - selecting multiple items from a menu<

windows

Guest
Hello, I have a form with a menu that can have multiple values selected. If I submit the form, the PHP page only recognizes one of the selected values. How can I fix this so the PHP page sees all the values selected?

Here's what the menu looks like:

echo '<tr><td align=center>';
echo "<b>Status:</b><br>";
echo "Hold &ltctrl&gt Key to Select Multiple Statuses";
echo "<p>&nbsp</p>";
$query = "select status_key, status from app_stats.queue_status order by status_key";
$cursor = OCIParse ($connection, $query);
if ($cursor == false){
echo OCIError($cursor)."<BR>";
exit;
}
$result = OCIExecute ($cursor);
if ($result == false){
echo OCIError($cursor)."<BR>";
exit;
}
echo '<select name = "status" size=10 multiple>';
while (OCIFetchInto ($cursor, $values)){
$status_key = $values[0];
$status = $values[1];
echo "<option value=$status_key>$status</option>";
}
echo '</select>';
echo '</td></tr>';

echo '<tr><td align=center>';
echo '<p align=center><input type="submit" name="submit" value="Submit">';
echo '</td></tr>';
echo '</table>';
echo '</form>';

Thanks in advance for any help.easy, since you have the multiple in the select tag

echo '<select name = "status" size=10 multiple>';

you need to access those with the aray it creates on submit.

status[1]

depending on how many was selected depends on how high the number goes
 
Back
Top