📄 urladdok.asp
字号:
<%@ LANGUAGE="VBSCRIPT" %>
<%option explicit%>
<%Dim wid,site,classid,url,about,show,showorder,hzhb,eer,rs,rsstr%>
<!--#include file="conn.asp"-->
<%
if session("admin")="" then
response.redirect "admin.asp"
end if
site=request("site")
classid=request("fenlei")
url=request("url")
about=request("about")
showorder=request("showorder")
show=request("show")
hzhb=request("hzhb")
if site="" then response.redirect "add.asp"
if classid="" then response.redirect "add.asp"
if url="" then response.redirect "add.asp"
'if showorder="" then response.redirect "add.asp"
if show="" then response.redirect "add.asp"
if hzhb="" then response.redirect "add.asp"
showorder=conn.execute("select count(*) from urls where classid="&classid)(0)+1
set rs=Server.CreateObject("ADODB.Recordset")
rsstr="select * from [urls]"
rs.open rsstr,conn,1,2
dim errr
errr=0
if rs.recordcount>0 then
if rs("site")=site and rs("url")=url then errr=1
end if
if errr=1 then eer="请不要重复添加,<br/>正在返回添加首页!<br/>"
if errr<>1 then
rs.addnew
if site<>"" then rs("site")=site
if url<>"" then rs("url")=url
if about<>"" then rs("about")=about
if classid<>"" then rs("classid")=classid
if showorder<>"" then rs("showorder")=showorder
if show<>"" then rs("show")=show
if hzhb<>"" then rs("hzhb")=hzhb
rs("check")=1
rs.update
rs.close
set rs=Nothing
conn.close
set conn=nothing
end if
%>
<html>
<head>
<title>添加成功</title>
<meta http-equiv="refresh" content='2; URL=urladd.asp'>
</head>
<body>
<p align="center">
<%if eer="" then%>
<b>网址添加成功!</b>
<%else%>
<b><%=eer%></b>
<%end if%></p>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -