<select id = "cityList" >
<select id = "selectId" >
<option value = "0"> 0 </option>
</select>
<script>
var selectObj = document.getElementById('selectId');
// option
selectId.add(new Option(" ","1"))
selectId.add(new Option(" ","2"))
// id option
selectId.add(new Option(" ","3"))
selectId.add(new Option(" ","4"))
// id ( )
selectId.onchange = function(){
// value text
alert(selectObj.value);
alert(selectObj.options[selectObj.selectedIndex].text);
// id value text
alert(selectId.value);
alert(selectId.options[selectId.selectedIndex].text);
// this value text
alert(this.value);
alert(this.options[this.selectedIndex].text);
};
</script>