<select id="target">
<option value="1">...</option>
<option value="2">...</option>
</select>
views:
3030answers:
2Should be noted that this more easily done with $("#target")[0].selectedIndex = 0;
David Andres
2009-09-12 04:34:00
Good second approach. Please add the value of the selected attribute. For example, attr("selected", "selected"). Without this extra parameter, the selection isn't made.
David Andres
2009-09-12 04:36:26