📄 question.jsp
字号:
<%@page contentType="text/html;charset=gb2312" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>系统提示:</title>
</head>
<body ondblclick=Submit_onDoubleclick()>
<script type="text/javascript" language="javascript">
function sAlert(str){
var msgw,msgh,bordercolor;
msgw=400;//提示窗口的宽度
msgh=100;//提示窗口的高度
titleheight=25 //提示窗口标题高度
bordercolor="#c51100";//提示窗口的边框颜色
titlecolor="#c51100";//提示窗口的标题颜色
var sWidth,sHeight;
sWidth=screen.width;
sHeight=screen.height;
var bgObj=document.createElement("div");
bgObj.setAttribute('id','bgDiv');
bgObj.style.position="absolute";
bgObj.style.top="0";
bgObj.style.background="#cccccc";
bgObj.style.filter="progid:DXImageTransform.Microsoft.Alpha(style=3,opacity=25,finishOpacity=75";
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);
var msgObj=document.createElement("div")
msgObj.setAttribute("id","msgDiv");
msgObj.setAttribute("align","center");
msgObj.style.background="white";
msgObj.style.border="1px solid " + bordercolor;
msgObj.style.position = "absolute";
msgObj.style.left = "50%";
msgObj.style.top = "50%";
msgObj.style.font="12px/1.6em Verdana, Geneva, Arial, Helvetica, sans-serif";
msgObj.style.marginLeft = "-225px" ;
msgObj.style.marginTop = -75+document.documentElement.scrollTop+"px";
msgObj.style.width = msgw + "px";
msgObj.style.height =msgh + "px";
msgObj.style.textAlign = "center";
msgObj.style.lineHeight ="25px";
msgObj.style.zIndex = "10001";
var title=document.createElement("h4");
title.setAttribute("id","msgTitle");
title.setAttribute("align","right");
title.style.margin="0";
title.style.padding="3px";
title.style.background=bordercolor;
title.style.filter="progid:DXImageTransform.Microsoft.Alpha(startX=20, startY=20, finishX=100, finishY=100,style=1,opacity=75,finishOpacity=100);";
title.style.opacity="0.75";
title.style.border="1px solid " + bordercolor;
title.style.height="18px";
title.style.font="12px Verdana, Geneva, Arial, Helvetica, sans-serif";
title.style.color="white";
title.style.cursor="pointer";
title.innerHTML="关闭";
title.onclick=function(){
document.body.removeChild(bgObj);
document.getElementById("msgDiv").removeChild(title);
document.body.removeChild(msgObj);
}
document.body.appendChild(msgObj);
document.getElementById("msgDiv").appendChild(title);
var txt=document.createElement("p");
txt.style.margin="1em 0"
txt.setAttribute("id","msgTxt");
txt.innerHTML=str;
document.getElementById("msgDiv").appendChild(txt);
}
</script>
<%
String kehuip=request.getRemoteAddr();
String postname=request.getParameter("postname");
String posttel=request.getParameter("posttel");
String postmail=request.getParameter("postmail");
String postinfo=request.getParameter("Question");
String url=request.getParameter("url");
String zuozhe=request.getParameter("zuozhe");
String yearsold=request.getParameter("yearsold");
String elevel=request.getParameter("elevel");
String elan=request.getParameter("elan");
if(postname.length()<2 || posttel.length()<7 || postmail.length()<3 || postinfo.length()<5){
out.print("<script language=\"JavaScript\">\r\n <!--\r\n sAlert(\"We can contact you in order to give you back your advice, do not forget to leave your name and contact^_^!\"); \r\n \r\n// -->\r\n </script>");
out.print("<script language=\"JavaScript\">\r\n <!--\r\n alert(\"We can contact you in order to give you back your advice, do not forget to leave your name and contact^_^!\"); \r\n location.href='javascript:history.back(1)'; \r\n// -->\r\n </script>");
return;
}
String xianzhiip="222.46.18.34;211.144.92.96;218.83.155.134;61.152.169.27;61.152.169.27;222.46.18.34";
if (xianzhiip.indexOf(kehuip)!=-1 ) {
out.print("<script language=\"JavaScript\">\r\n <!--\r\n alert(\"You input the content is not included HTML signs!\"); \r\n location.href='http://www.i-labor.cn/?errr=You input the content is not included HTML signs。'; \r\n// -->\r\n </script>");
return;
}
String postinfo_guolv="<";String postinfo_guolv2=">";String postinfo_guolv3=">";String postinfo_guolv4="=";String postinfo_guolv5="http";
if (postinfo.indexOf(postinfo_guolv)!=-1 || postinfo.indexOf(postinfo_guolv2)!=-1 || postinfo.indexOf(postinfo_guolv3)!=-1 || postinfo.indexOf(postinfo_guolv4)!=-1 || postinfo.indexOf(postinfo_guolv5)!=-1 ) {
out.print("<script language=\"JavaScript\">\r\n <!--\r\n sAlert(\"You input the content is not included HTML signs!\"); \r\n \r\n// -->\r\n </script>");
out.print("<script language=\"JavaScript\">\r\n <!--\r\n alert(\"You input the content is not included HTML signs!\"); \r\n location.href='http://www.i-labor.cn/??errr=You input the content is not included HTML signs。'; \r\n// -->\r\n </script>");
return;
}
%>
<%@page contentType="text/html;charset=gb2312" %>
<jsp:useBean id="server" scope="page" class="db.mysql.page"/>
<jsp:useBean id="sendMail" scope="page" class="mails.Email" />
<% String zctime="";
zctime=server.getTimeA();
%>
<% //内容内容----------------------
String body="";
body+="客户名称: "+postname+"";
body+="客户电话:"+posttel+" ";
body+="客户EMAIL:"+postmail+"";
body+="提交时间: "+zctime+" ";
body+="客户IP地址: "+kehuip+" ";
body+="咨询问题内容:";
body+="【"+postinfo+" 】<br>";
// 密码信标题
String title="i-labor网站首页:客户-"+postname+" -的问题";
%>
<%String send_emails="邮箱@163.com";//发件人
String send_email="邮箱@163.com";//发信认证油箱
String send_email_password="密码";
String smtp_server="smtp.163.com";
%>
<%
String request_email="hykchen@hotmail.com"; //收件人
sendMail.sendMail(send_emails,send_email,request_email,title,body,smtp_server,send_email,send_email_password);
%>
<%
out.print("<script language=\"JavaScript\">\r\n <!--\r\n alert(\"Hi^_^"+postname+"Your problem has been sent to our professional customer service staff, we will leave the links based on your way back to your questions, and you get more detailed negotiations. Point determined to return to Home!\"); \r\n location.href='http://www.i-labor.cn/'; \r\n// -->\r\n </script>");
out.print("<script language=\"JavaScript\">\r\n <!--\r\n sAlert(\"Hi^_^"+postname+"Your problem has been sent to our professional customer service staff, we will leave the links based on your way back to your questions, and you get more detailed negotiations. Point determined to return to Home!\"); \r\n \r\n// -->\r\n </script>");
//out.print("读取数据"+zctime+postname+postinfo+zzemail+kehuip+posttel+zzemail2);
%>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -