当执行这个函数的时:
$("#oprType").change(function() { //节点操作(添加节点、编辑节点、删除节点)
var selectType = $("#oprType").find("option:selected").val();
if(selectType == "0") { //selectType为0执行增加节点操作
$("#nodeName").show();
$("#principalName").show();
$("input[name='nodeName']").show();
$("input[name='editNodename']").hide();
$("input[name='principal']").show();
$("input[name='editPrincipal']").hide();
$("#NoteText").show();
$("#txtarea").show();
$("#EditTxtarea").hide();
}
if(selectType == "1" || selectType == "3") { //selectType为1执行删除节点操作
$("#nodeName").hide();
$("#principalName").hide();
$("#NoteText").hide();
}
if(selectType == "2") { //selectType为2执行编辑节点操作
$("#nodeName").show();
$("#principalName").show();
$("#NoteText").show();
$("#txtarea").hide();
$("#EditTxtarea").show();
$("input[name='nodeName']").hide();
$("input[name='editNodename']").show();
$("input[name='principal']").hide();
$("input[name='editPrincipal']").show();
}
});
浏览器就报错:
试下换个别的版本的jq库