var bgObj=document.createElement("div");
function showMsgFrm(Mode)
{
var sWidth,sHeight;
sWidth=document.body.offsetWidth;
sHeight = 917;
//document.all.TipsDiv.style.zindex = 10002;
bgObj.setAttribute('id','bgDiv');
bgObj.style.position="absolute";
bgObj.style.top="0";
bgObj.style.background="#777";
bgObj.style.filter="progid:DXImageTransform.Microsoft.Alpha(style=2,opacity=40,finishOpacity=60";
bgObj.style.opacity="0.6";
bgObj.style.left="0";
bgObj.style.width=sWidth + "px";
bgObj.style.height=sHeight + "px";
bgObj.style.zIndex = "10000";
document.body.appendChild(bgObj);
switch(Mode)
{
	case "WriteMsg":
bgObj.style.display = "block";
document.all.sendMsg.style.display = "block";
break;
	case "AdminLogin":
	bgObj.style.display = "block";
document.all.AdminLogin.style.display = "block";
break;
}
}
function clsMsgFrm(Mode)
{
	switch(Mode)
	{
		case "WriteMsg":
bgObj.style.display = "none";
document.all.sendMsg.style.display = "none";
document.all.TipsDiv.style.zindex = 1;
document.getElementById("CurWords").innerHTML = "当前字数:0";
document.getElementById("RemWords").innerHTML = "剩余字数:700";
document.all.Name.value = "";
document.all.mail.value = "";
document.all.selFace[0].selected=true;
document.all.ShowFace.src = "Images/Face/1.gif"
document.all.QQ.value = "";
document.all.Content.value = "";
break;
		case "AdminLogin":
bgObj.style.display = "none";
document.all.AdminLogin.style.display = "none";
document.all.AdminName.value = "";
document.all.AdminPass.value = "";
	}
}


function Send()

{
	
	var content1=$.trim($("#content1").val());
	if(content1 == ''){
                    alert('请您填写留言内容');
	 return false;
	 }
	 
	 
	
	 var badword = new Array("射精","傻逼","【碧】","你妈逼","去你的","草你爷爷","    ","滚蛋","▅▅","碧聊战士","操你妈","死鸭子","鴨子","破 鞋","吃屎","我操","操你","操 你","骚 逼","干死你","妈■","▓","破鸭子","贱人","婊子","表子","婊","婊·子","婊$子","靠你","插你","插死","干死","日死","鸡巴","睾丸","包皮","奶子","尻","爷●","鸡八","处女","打炮","叼你","草你","狗屎","鸡·巴","▁▂▃▄▅▆▇","操 你 妈","爺","●●","****","cao","日你","我 操","老 逼","狗男女","叫床","叫春","我靠","妈的","靠");
	 for (var i=0;i<badword.length;i++)
{
  if (content1.indexOf(badword[i]) >= 0)
  {
   alert('请不要说脏话');
    return false;
  }
}

	 
			
		var $qyqc		=$('#qyqc').val();
		var $chz		=$('#chz').val();
		var $mbphone	=$('#mbphone').val();
		var $content1   =$('#content1').val();
	$.ajax(
		   
		   
		   {
		url:"do.asp?action=ajax_send&qyqc="+escape($qyqc)+"&chz="+escape($chz)+"&mbphone="+escape($mbphone)+"&content1="+escape($content1),
		type:'GET',
		success:function(xml){
							document.all.sendMsg.style.display = "none";
							document.all.bgDiv.style.display = "none";
											alert(xml);




			
			
		}

		
	}
	);
	
	
	}
	


