jquery Get Set Drop-down menu value, add drop-down menu element, empty dropdown box content
Remove the text of the selected item from the Pull menu
$ ("#select option[selected]"). Text ();//select and option have spaces, option is child element of select
$ ("#select option:selected"). Text ()//if written as $ ("#select"). Text () Select all Drop-down menu texts
2. Get and set the value of the Drop-down menu
$ ("#select"). Val ();//Fetch value
$ ("#select"). Val ("value");/setting, if there is an option in the select that has value, the option is selected, and if it does not exist, the select does not make any changes
3. Empty the Pull-down menu
$ ("#select"). empty ();
$ ("#select"). HTML ("");
4. Add elements to the following menu
$ (' <option value= "1" >1</option> "). Appendto ($ (" #select "));
$ ("#select"). Append (' <option value= ' 1 ">1</option> ');