📄 bookadd.asp
字号:
<%@LANGUAGE="VBSCRIPT" CODEPAGE="936"%><!--#include file="conn.asp"--><!--#include file="md5.asp"--><%
dim actions
actions = trim(request("action"))
if actions = "addbook" then
if qwbmbkset2 = 0 then '是否打开留言
call errbox(""& qwbmbkset4 &"","","","","")
end if
dim qna,qlz,email,qqq,qxb,qtx,qwb,qxq,qly,ip,sessid,qc,qcm,qyz,qyz1
qna=plhtml(replace(trim(request("b_name")),"'","")) '留言者的名称
if qna = "" then
call errbox("姓名不能为空","","","","")
elseif len(qna) < 2 then
call errbox("姓名太短了","","","","")
elseif len(qna) > 10 then
call errbox("姓名太长了","","","","")
end if
call adcallobj(qna)
qqq=plhtml(replace(trim(request("b_qq")),"'","")) '留言者的QQ
if qqq="" then
call errbox("QQ不能为空,请填写你的QQ方便我与你联系","","","","")
elseif len(qqq) < 5 then
call errbox("这么短的QQ,你是第一代的QQ用户吗?","","","","")
elseif len(qqq) > 11 then
call errbox("这么长的QQ,还没有见过","","","","")
end if
call adcallobj(qqq)
qem=plhtml(replace(trim(request("b_email")),"'","")) '留言者的EMail
if len(qem) > 30 then
call errbox("请认真填写你的email","","","","")
end if
call adcallobj(qem)
qwb=plhtml(replace(trim(request("b_url")),"'","")) '留言者的个人网站
if len(qwb) > 30 then
call errbox("有这么长的网址吗?网址太长了吧,是二级域名吗?\n\n请认真填写你的网址","","","","")
end if
call adcallobj(qwb)
qlz=plhtml(replace(trim(request("b_form")),"'","")) '留言者来自于那里?
if len(qlz)>20 then
call errbox("你来自于那里?地址太长了吧","","","","")
end if
call adcallobj(qlz)
qxq=plhtml(replace(trim(request("b_xinqing")),"'","")) '留言心情
if qxq = "" then
call errbox("请选择您当前的心情","","","","")
end if
qly=plhtml(replace(trim(request("b_conter")),"'","")) '留言内容
if len(qly) < 8 then
call errbox("留言内容太短了,最低不能少于 8 个字符","","","","")
elseif len(qly) > qwbmbkset6 then
call errbox("留言内容太长了,最多不可超多 "& qwbmbkset6 &" 个字符,当有输入 "& len(qly) &" 个字符","","","","")
end if
call adcallobj(qly)
qc=plhtml(replace(trim(request("ca")),"'",""))
qcm=plhtml(replace(trim(request("cakan")),"'",""))
if qc="" then
qc=0
else
qc=1
end if
if qc = 1 and qcm="" then '回复查看码
call errbox("选择留言悄悄话模式后,回复查看码不能为空,请输入您的回复查看码","","","","")
elseif qc <> 1 and qcm<>"" then
call errbox("回复查看码不正确","","","","")
end if
qxb=left(plhtml(replace(trim(request("m1")),"'","")),1)
qtx=plhtml(replace(trim(request("m1")),"'","")) & ".gif"
if qxb="" then
call errbox("请选择头像","","","","")
end if
qyz=session("qwbmbook_Code")
qyz1=plhtml(replace(trim(request("yianzhen")),"'",""))
if qyz1="" or len(qyz1)<4 or not isnumeric(qyz1) then
call errbox("请正确输入验证码","","","","")
elseif qyz1<>qyz then
call errbox("验证码不正确\n\n请正确输入验证码!!!","","","","")
end if
ip=Request.ServerVariables("REMOTE_ADDR")
sessid=session.sessionid
shenhe=qwbmbkset3
gsql="select * from qwbmbook where liuyan='"&qly&"'"
set grs=server.createobject("adodb.recordset")
grs.open gsql,conn,1,1
if not grs.eof and not grs.bof then
call errbox("请不要重复提交留言\n\n谢谢","","","","")
end if
grs.close
set grs=nothing
absql="select * from qwbmbook"
set abrs=server.createobject("adodb.recordset")
abrs.open absql,conn,1,3
abrs.addnew
abrs("name")=qna
abrs("qicq")=qqq
abrs("email")=qem
abrs("web")=qwb
abrs("laizi")=qlz
abrs("lei")=ql
abrs("xinq")=qxq
abrs("liuyan")=qly
if qcm="" then
abrs("baomima")=qcm
else
abrs("baomima")=md5(qcm)
end if
abrs("xinb")=qxb
abrs("toux")=qtx
abrs("ip")=ip
abrs("shenhe")=shenhe
abrs.update
abrs.close
set abrs=nothing
if qwbmbkset3="1" then
call errbox("留言成功","index.asp","","","")
elseif qwbmbkset3="0" then
call errbox("留言成功,等待管理员审核","index.asp","","","")
end if
conn.close
set conn=nothing
response.end
end if
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title><%=qwbmset2%>——Powered By Qwbm</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<meta name="KeyWords" content="<%=qwbmset3%>">
<meta name="Description" content="<%=qwbmset4%>">
<meta name="generator" content="dreamwerver8" />
<meta name="author" content="www.qwbm.com,深山行者" />
<meta name="copyright" content="Copyright 2008,www.qwbm.com,深山行者,565449214" />
<link type="image/x-icon" href="favicon.ico" rel="shortcut icon" />
<link type="image/x-icon" href="favicon.ico" rel="icon" />
<link href="skin/<%=qwbmbkset11%>/book.css" rel="stylesheet" type="text/css" />
<script language="javascript" type="text/javascript" src="js/book.js"></script>
</head>
<body>
<!--container start-->
<div id="container">
<%call header("2","","","","")%>
<!--***********************************main start***********************************-->
<div id="main">
<div class="tc"><div class="tl"></div><div class="tr"></div></div>
<!--class_cnt1 start-->
<div id="class_cnt1">
<dl id="displayimgs" class="qqdiv" >
<dd>
<ul>
<li><img src="./images/tu/m01.gif" alt="女" onClick="faces('m01');" /></li>
<li><img src="./images/tu/m02.gif" alt="女" onClick="faces('m02');" /></li>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -