var postmaxchars = 0; var isadmin = "0"; function checklength(theform) { if (postmaxchars != 0) { message = "系统限制: 0 字节"; } else { message = ""; } alert("
当前长度: "+theform.message.value.length+" 字节

"+message); } function validate(theform) { if (theform.message.value == "" && theform.subject.value == "") { alert("请完成标题或内容栏。"); return false; } if (postmaxchars != 0 && isadmin != 1) { if (theform.message.value.length > 0) { alert("您的帖子长度超过限制

当前长度: "+theform.message.value.length+" 字节
系统限制: 0 字节"); return false; } else { return true; } } else { return true; } }
“中南海”保镖
Share |
Share

TOP