jQuery get selected option text


jQuery get selected option text: You can get selected option text in select box as below.


Syntax : jQuery get selected option text

Syntax to get selected option textof dropdown menu can be as :
Suppose we have following drop down list


<select id="demo">
    <option value="0">first</option>
    <option value="1">second</option>
    <option value="2">third</option>
</select>

You can get selected value in jquery as :


$("#demo").change(function () {
$("#demo :selected").text();

});

Try it »


Advertisements

Add Comment

📖 Read More