I have to choose an option from a html file:
<select id="color">
<option>red</option>
<option>yellow</option>
<option>green</option>
<option>orange</option>
</select>
for example i want to select green. I have already tried:
var color = "green"
document.getElementById("color").options.value = color;
document.getElementById("color").value = color;
but they don't work. (option tag must be withouth name, id, ...)