在线留言
<form class="Msg" method="post" action="" id="msg" onsubmit="return checkForm();">
<p><div class="label">姓名</div><input type="text" size="30" maxlength="245" name="Sender"/>
<p><div class="label">电话</div><input type="text" size="30" maxlength="100" name="Link"/>
<p><div class="label">邮箱</div><input type="text" size="30" maxlength="200" name="Email"/>
<p><div class="label">评论</div><textarea cols="45" rows="8" maxlength="65525" name="Content"></textarea>
<p><input type="submit" name="submit" id="submit" value="发表评论">
<input type="hidden" name="coid" value="<?变量:coid?>" />
<input type="hidden" name="act" value="Message" />
</form>
<script type="text/javascript">
function checkForm(){
var content = $("textarea[name='Content']").val();
if(content == ""){
return false;
}
return true;
}
$("#msg").submit(function(){
window.location.reload();
});
</script>