hi Is there any way through which we can get all the selected values in a list box?
you can delete it, by clicking `delete` link.
SilentGhost
2009-07-16 16:46:32
A:
If you're using PHP, you can give the select an array-style name:
<select name="items[]" multiple>
<option value="option-1">Option 1</option>
<option value="option-2">Option 2</option>
<option value="option-3">Option 3</option>
</select>
Accessing these values from the server-side is rather simple:
<?php
foreach ($_POST["items"] as $value) {
echo $value . "<br/>";
}
?>
Jonathan Sampson
2009-07-16 16:47:36