I have a select control, and in a javascript variable I have a text string.
Using jQuery I want to set the selected element of the select control to be the item with
I found that by using attr you would end up with multiple options selected when you didn't want to - solution is to use prop:
attr
prop
$("#myDropDown option:text=" + myText +"").prop("selected", "selected");