I'd like to be able to display the optgroup label attribute value after a
select list is changed. This is what I have so far, but I think I'm heading
down the wrong track, because a) I want the optgroup label value, not the
selected option value and b) I don't want to keep appending if the user
changes the selection more than once...

$(document).ready(function() {
  $('#MySelect').change( function() { 
                $('#MySelect').after('('+$('#MySelect').val()+')'); 
  } ) ;
});

Any help would be appreciated :)

~Philip
-- 
View this message in context: 
http://www.nabble.com/Getting-the-optgroup-for-a-select-option-tf3023854.html#a8400070
Sent from the JQuery mailing list archive at Nabble.com.


_______________________________________________
jQuery mailing list
[email protected]
http://jquery.com/discuss/

Reply via email to