<script type="text/javascript">
//alert("测试下拉选项联动");
$("#field16").change(function(){
alert(1);
var aaa=document.getElementById("field16").value;
alert(aaa);
if(aaa=="黑龙江"){
alert("3333");
document.getElementById("field17").options.length=0;
document.getElementById("field17").options.add(new Option("齐齐哈尔", "齐齐哈尔"));
document.getElementById("field17").options.add(new Option("哈尔滨", "哈尔滨", false, true)); // 默认选中省会城市
}
if(aaa=="吉林"){
alert("444");
document.getElementById("field17").options.length=0;
document.getElementById("field17").options.add(new Option("吉林", "吉林"));
document.getElementById("field17").options.add(new Option("长春", "长春", false, true)); // 默认选中省会城市
}
});
</script>
field16为省份
filed17为城市
将以上代码添加到EditView.php最下方