function CheckForm() {
if(document.theForm.NewsCont.value == ""){
alert("文章内容不能为空!");
document.theForm.NewsCont.focus();
return false;
}
}
if(document.theForm.NewsCont.value == ""){
alert("文章内容不能为空!");
document.theForm.NewsCont.focus();
return false;
}
}
s = s.replace(/(^\s+)|(\s+$)/gm,"");
if(s == ""){
alert();
....
}
if(o.NewsCont.value == ""){
alert("文章内容不能为空!");
o.NewsCont.focus();
return false;
}
return true;
}
function CheckForm() {
if(document.theForm.NewsCont.value == ""){
alert("文章内容不能为空!");
return false;
}
return true;
}
去掉就可以了。