<select name="cs" id="cs"> <option value="3" >03</option>
<option value="2" >02</option>
</select>
<div id="content"></div>
<script type="text/javascript">
var myid = document.getElementById("cs");
document.getElementById("content").innerHTML = '<input name="xingming"></input><input name="xingbie"></input><input name="nianling"></input>';
// 通过id添加方法(也可以通过对象添加方法)
myid.onchange = function(){
// 通过对象获取value
if(myid.value == 3){
document.getElementById("content").innerHTML = '<input name="xingming"></input><input name="xingbie"></input><input name="nianling"></input>';
}else{
document.getElementById("content").innerHTML = '<input name="dizhi"></input><input name="youbian"></input>';
}
};
</script>