skin_add_save.asp

来自「欢迎使用《雨点下载系统 2.0》! 本系统仅提供给个人网站免费使用」· ASP 代码 · 共 38 行

ASP
38
字号
<!--#include file="conn.asp"-->
<!--#include file="chkadmin.asp"-->
<!--#include file="inc/char.asp"-->
<%dim SkinName,errmsg,founderr
SkinName=Trim(Request.Form("SkinName"))
founderr=false

if chkadmin=false or power(5)="0" then
	founderr=true
	errmsg=errmsg+"<li>您没有添加配色方案的权限</li>"
end if

if SkinName="" then
	founderr=true
	errmsg=errmsg+"<li>方案名称不能为空</li>"
end if

if strlen(SkinName)<2 or strlen(SkinName)>10 then
	founderr=true
	errmsg=errmsg+"<li>方案名称应为2~10个字符</li>"
end if

if founderr=false then
	conn.execute("insert into Skin (SkinName,SkinSetting) values ('"&SkinName&"',',,,,,,,,,,,,,,,,,,')")
	dim sql,rs
	sql="select top 1 ID from Skin order by ID desc"
	set rs=conn.execute(sql)
	dim gourl,msg
	gourl="skin_list.asp?id="&rs(0)
	msg="配色方案添加成功!"
	set rs=nothing
	call ok()
else
	call error()
end if

conn.close
set conn=nothing%>

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?