function ComboAnio(){
var meses = new Array("01", "02", "03", "04", "05", "06", "07", "08", "09", "10", "11", "12");
var d = new Date();
var n = d.getMonth();
var y = d.getFullYear();
var select = document.getElementById("selectFechaVigencia1");
$("#selectFechaVigencia1").html("");
$("#selectFechaVigencia1").append('<option value="other">Seleccionar...</option>');
for (var i = n; i >= n - 2; i--) {
var opc = document.createElement("option");
opc.text = y + "-" + meses[i];
opc.value = i;
select.add(opc)
}
}
<html DOCTYPE!>
<script src="http://code.jquery.com/jquery-1.6.1.min.js"></script>
<head>
<body>
<select id="selectFechaVigencia1" onclick="ComboAnio();">
<option value="">seleccionar...</option>
</select>
</body>
</head>
</html>
What I want is for any value that I select from the combo to be selected.