I can't quite get my Javascript to select this item in a list. There are two identifiers that I must use to select an item in a list, using Javascript in an Applescript. I can't feasibly script the GUI, so this must be done programatically. Below is my latest effort.
HTML Tag and Value:
<option value="48">48 - State</option>
Javascript attempt:
do JavaScript "var elements = document.getElementsByTagName('option');
for (i=0;i<elements.length;i++) {
if(elements[i].value == '48') {
elements[i].checked = true;
}
}" in doc