60
rated 0 times
[
63]
[
3]
/ answers: 1 / hits: 45851
/ 10 Years ago, tue, april 22, 2014, 12:00:00
<select id=comboBox>
<option id=1>One</option>
<option id=2>Two</option>
<option id=3>Three</option>
<option id=4>Four</option>
</select>
I want to select option with ID 3. Is there any way how to do it without loop? I expect something like this
$(#comboBox).val(3);
but with ID instead of value. (So I mean to access that option as member of comboBox, not through selector like document.getElementById('3');
)
More From » html