Answers for "jquery set dropdown selected value by text"

3

how to get the selected text of dropdown in jquery

BY LOVE
$("#Id option:selected").text()
Posted by: Guest on July-13-2020
0

how to set dropdown value in textbox using jquery

$('#chosen_a').change(function(){
     //get the selected option's data-id value using jquery `.data()`
      var criteria_rate =  $(':selected',this).data('id'); 
     //populate the rate.
    $('.criteria_rate').val(criteria_rate);
});
Posted by: Guest on May-13-2020

Code answers related to "jquery set dropdown selected value by text"

Code answers related to "Javascript"

Browse Popular Code Answers by Language