I have a select Input menu that is created dynamically, This creates a row item. The user can then click the row to edit their selection. I am having a problem setting the default drop down option to a variable. I put a simplified version of my problem in a jsfiddle.
http://jsfiddle.net/SteveRobertson/cPtLj/1/
What I am trying to do in the fiddle is have the default option be option3.
I have also tried using "value" instead of "text" and doing this
$("#selectid option[value='"+cat+"']").prop("selected", "selected");
I can not seem to get the value to set. Any help would be appreciated. Thank you.