I'm trying to create a simple select element.
The options' length isn't known in advance, and depend on the user's input.
The code I'm currently using is:
<html>
<head>
</head>
<body>
<table border="0" width="100%" cellspacing="0" cellpadding="0">
<tbody>
<tr>
<td valign="top" width="325">
<select multiple="" size="10" style="overflow-x:auto; overflow-y:auto; width:320px;">
<option value="a1">aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa</option>
<option value="b1">bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb</option>
</select>
</td>
</tr>
</tbody>
</table>
</body>
</html>
I'd like the select element to have a fixed width, and then when long lines are entered the user should be able to scroll.
The Problem
Using the current code truncates the option's text when I select it (number of 'a's is equal to number of 'b's):
Does anyone know how to fix the truncation when selecting an option?