showskin.asp

来自「是个不错的文件代码,希望大家好好用,」· ASP 代码 · 共 64 行

ASP
64
字号
<!--#include file="conn.asp"-->
<%
dim rs,skinid,userid,teamid,teamskinid
dim show,skinshowlog,i
skinid=clng(request("id"))
userid=clng(request("userid"))
teamid=clng(request("teamid"))
teamskinid=clng(request("teamskinid"))
if not IsObject(conn) then link_database
if skinid>0 then
	set rs=conn.execute("select skinmain,skinshowlog from oblog_userskin where id="&skinid)
	if rs.eof then
		response.write "模板不存在!"
	else
		skinshowlog=rs(1)
		for i=1 to 6
			skinshowlog=skinshowlog+rs(1)
		next
		show=replace(rs(0),"$show_log$",skinshowlog)
		response.write show
	end if
	
elseif teamskinid>0 then
	set rs=conn.execute("select skinmain from oblog_teamskin where id="&teamskinid)
	if rs.eof then
		response.write "模板不存在!"
	else
		response.write rs(0)
	end if

elseif userid>0 then
	set rs=conn.execute("select bak_skin1,bak_skin2 from oblog_user where userid="&userid)
	if rs.eof then
		response.write "用户不存在!"
	else
		if rs(0)="" or rs(1)="" or isnull(rs(0)) or isnull(rs(1)) then
			response.Write("当前没有备份模板")
		else
			skinshowlog=rs(1)
			for i=1 to 6
				skinshowlog=skinshowlog+rs(1)
			next
			show=replace(rs(0),"$show_log$",skinshowlog)
			response.write show
		end if
	end if
	
elseif teamid>0 then
	set rs=conn.execute("select skin_bak from oblog_teaminfo where teamid="&teamid)
	if rs.eof then
		response.write "用户不存在!"
	else
		if rs(0)=""  or isnull(rs(0)) then
			response.Write("当前没有备份模板")
		else
			response.write rs(0)
		end if
	end if

end if
set rs=nothing
if isobject(conn) then conn.close:set conn=nothing

%>

⌨️ 快捷键说明

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