I am struggling to get the Javascript action going in the "onchange" event in the below example. I have tried all sorts of different syntax, but it does not work.
function display(){
$headingData ='<select name="input" id="input" onchange="$("#frmInput").submit()" >';
$headingData.='<option value="...." '.$selected.'>Selection1</option>';
$headingData.='<option value="...." '.$selected.'>Selection2</option>';
$headingData.='</select>
return $headingData;
}