📄 add_info_ok.asp
字号:
<!--#include file="../checkuser.asp" -->
<!--#include file="../../Include/db_conn.asp" -->
<!--#include file="../../Include/pub_func.asp" -->
<%
id=request("id")
m_Ver=request("ver")
isindex=request.Form("isindex")
if isindex="" then isindex="0"
edit_type=request("edit_type")
title = request.Form("title")
content=repSingleQuo(request.Form("content"))
if edit_type="add" then ''当添加新信息时
editstr="添加"
lssql ="insert into ys_info(title,content,isindex,version) values("
lssql=lssql&"'"& title & "','"& content &"','0','"&m_ver&"')"
conn.execute(lssql)
ok_and_return
elseif edit_type="edit" then ''当修改信息时
editstr="修改"
lssql ="update ys_info set title='"& title &"',content='"& content &"' where id = "& id &""
conn.execute(lssql)
ok_and_return
elseif edit_type="release" then ''当审核信息时
editstr="审核"
lssql ="update ys_info set release='1' where id in ("& id &")"
'response.Write lssql
'response.End
conn.execute(lssql)
elseif edit_type="del" then ''当删除信息时
editstr="删除"
lssql="delete from ys_info where id in (" & id & ")"
conn.execute(lssql)
ok_and_return
elseif edit_type="isindex" then ''当信息设置默认首页时
editstr="设置为默认首页"
lssql="update ys_info set isindex='0'"
conn.execute(lssql)
lssql="update ys_info set isindex='1' where id in (" & isindex & ")"
conn.execute(lssql)
ok_and_return
end if
call closedb()
%>
<%
sub ok_and_return
%>
<html>
<head>
<meta http-equiv="refresh" content="1; url=list_info.asp?ver=<%=m_ver%>">
<link href="../include/styles.css" rel="stylesheet" type="text/css">
</head>
<body>
<table width="100%" height="455" border="0" cellpadding="0" cellspacing="0">
<tr>
<td width="100%" align="center"><br>
<table cellspacing=0 cellpadding=0 width=300 height=100 border=0 ID="Table1">
<tr><td></td><td align=center ><p>信息<%=editstr%>成功!</p>
<p>2秒后自动返回</p></td>
<td></td></tr>
</table>
</td>
</tr>
</table>
</body>
</html>
<%end sub%>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -