Javascript examples for jQuery:Select Dropdown
Get value from empty <select>
<html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <script type="text/javascript" src="https://code.jquery.com/jquery-1.5.2.js"></script> <script type="text/javascript"> $(function(){//from ww w . java 2 s . c o m console.log($('#foo').val()); }); </script> </head> <body> <select id="foo"></select> </body> </html>