Set select option : Form Select « jQuery « JavaScript DHTML
- JavaScript DHTML
- jQuery
- Form Select
Set select option
<html>
<head>
<script type="text/javascript" src="js/jquery-1.3.2.js"></script>
<script type="text/javascript">
$(document).ready(function(){
$("#single").val("Single2");
});
</script>
</head>
<body>
<body>
<select id="single">
<option>Single</option>
<option>Single2</option>
</select>
</body>
</html>
Related examples in the same category