On MVC3, with a dropdownlist defined as
@Html.dropDownList(m=>m.model, new SelectList(m.myList, "value", "text"))
How can I get the selected value and/or text via javascript?
I tried passing a name:
@Html.dropDownList(m=>m.model, new SelectList(m.myList, "value", "text"), new {name="name")
and reading the name from the javascript: document.getElementByName("name")
but that does not work.