⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 channel.asp

📁 本系统是一套开源WEB的网站管理系统
💻 ASP
字号:
<!--#include file="include/ms_setting.asp"-->
<%
'==============================================================
'程序名称:茂盛网站管理系统(Maoin CSM)
'当前版本:Maosin CMS Version 1.1   Powered by maosin.com
'程序作者:阿茂(李胜茂)
'网站地址:www.maosin.com  www.maosin.net
'      QQ:57861417  
'电子邮箱:maosin@163.com  maosin@maosin.com
'--------------------------------------------------------------
'Copyright (C) 2006  maosin.com All Rights Reserved.
'免费版本请在程序首页保留(Powered by:Maosin CMS)版权链接信息;
'您可以对此版本进行修改,美化,但请保留此ASP文件内的版权信息;
'茂盛设计网保留此软件的法律追究权利
'==============================================================
dim id,rootid,channelsql,ismode,iserror
id=request.queryString("id")
rootID=request.QueryString("rootID")
showmode=Request.QueryString("showMode")
if id<>"" and rootID="" then
	ismode=1
elseif id<>"" and rootid<>"" then
	ismode=2
elseif id="" and rootid<>"" then
	ismode=3
else
	ismode=0
end if
%>
<!--#include file="ms_start.asp"-->
<!--页面主体开始-->
<script language="JavaScript" src="include/wisdom.js"></script>
<table width="100%" align="center" border="0" cellpadding="0" cellspacing="0" class="mainMiddle_tdble"><tr>	
<%
if ismode=1 then
	if isInteger(id)=false then
		response.write("<td>")
		showMsg "<li>参数出错啦!</li><li>参数应为数字型字符</li>","参数出错"
		response.write("</td>")
	else
		channelSql="select * from ms_channel where rootid=0 and id="&id&" and sflag=1"
		LClassMenu channelSql,id
	end if
elseif ismode=2 then
	if isInteger(id)=false or isInteger(rootid)=false then
		response.write("<td>")
		showMsg "<li>参数出错啦!</li><li>参数应为数字型字符</li>","参数出错"
		response.write("</td>")
	else
		channelSql="select * from ms_channel where id="&rootid&" and rootid=0 and sflag=0"
		LClassMenu channelSql,id
	end if
elseif ismode=3 then
	if isInteger(rootid)=false then
		response.write("<td>")
		showMsg "<li>参数出错啦!</li><li>参数应为数字型字符</li>","参数出错"
		response.write("</td>")
	else
	channelSql="select * from ms_channel where id="&rootid&" and rootid=0 and sflag=0"
	LClassMenu channelSql,""
	end if
else
	response.write("<td>")
	showmsg "您提供的参数不足","参数出错"
	response.write("</td>")
end if	%>
</tr></table>
<!--#include file="ms_end.asp"-->
<%
Sub LClassMenu(csql,id)
	dim rs,crs,sql,i
	set rs=conn.execute(channelSql)
	if not rs.eof and not rs.bof then
		if ismode=1 then
			bodyConten=channelBody(rs("channel_title"),rs("channel_content"))
		else
			response.write("<td valign=""top"" class=""mainMiddle_td_left""><div class=""groupblock"">")
			response.write("<table border=""0"" cellpadding=""0"" cellspacing=""0"" width=""100%""><tr><td class=""ltl""><script type=""text/javascript"">ico()</script></td><td class=""ltc""><span class=""tt"">"&rs("channel_title")&"</span></td><td class=""ltr""></td></tr></table>")
			response.write("<div class=""lmc"">")
			set crs=conn.execute("select * from ms_channel where rootid="&rootid)
			if not crs.eof and not crs.bof then
			if id="" or isnull(id) then
				id=0
			end if
			i=1
			do while not crs.eof
				if cint(crs("id"))=cint(id) then
					bodyConten=channelBody(crs("channel_title"),crs("channel_content"))
				else
					if i=1 then
						bodyConten=channelBody(crs("channel_title"),crs("channel_content"))
					end if
				end if
				if crs("id")=cint(id) then
				response.write("<div class=""rlineX"">☉<a style=""color:#ff0000;"" href=""channel.asp?rootid="&crs("rootid")&"&id="&crs("id")&""">"&crs("channel_title")&"</a></div>")
				else
				response.write("<div class=""rlineX"">☉<a href=""channel.asp?rootid="&crs("rootid")&"&id="&crs("id")&""">"&crs("channel_title")&"</a></div>")
				end if
				i=i+1
				crs.movenext
			loop
			crs.close
			set crs=nothing
			response.write("</div></div></td>")
			response.write("<td class=""mainMiddle_td_middle"" onClick=""switchCol(this)"" title=""关闭左栏""><img src=""images/closeL.gif""></td>")
			else
				response.write("<td>")
				showMsg "对不起,此类还没有添加信息","出错信息"
				response.write("</td>")
			end if
		end if
		response.write bodyConten
	else
		response.write("<td>")
		showmsg "没有此频道,或者此频道已经删除了","出错信息"
		response.write("</td>")
	end if
	rs.close
	set rs=nothing
End Sub
Function channelBody(title,content)
dim strTemp
if ismode=1 then
	strTemp="<td valign=""top"" width=""100%"">"
	strTemp=strTemp&"<table border=""0"" cellpadding=""0"" cellspacing=""0"" width=""100%""><tr><td class=""rtl""><script type=""text/javascript"">ico()</script></td><td class=""rtc""><span class=""rtt"">当前位置:<a class=""classNavig"" href=""index.asp"">本站首页</a>→<a class=""classNavig"">"&title&"</a></span></td><td class=""rtr""></td></tr></table>"
else
	strTemp="<td valign=""top"" class=""mainMiddle_td_right"">"
	strTemp=strTemp&"<table border=""0"" cellpadding=""0"" cellspacing=""0"" width=""100%""><tr><td class=""rtl""><script type=""text/javascript"">ico()</script></td><td class=""rtc""><span class=""rtt"">"&title&"</span></td><td class=""rtr""></td></tr></table>"
end if
strTemp=strTemp&"<div class=""groupblock"">"
strTemp=strTemp&"<div class=""rmc"" style=""padding:5px;word-wrap:break-word;"">"&content&"</div>"
strTemp=strTemp&"</div>"
strTemp=strTemp&"</td>"
channelBody=strTemp
End Function
'========================================================
'MaoSin CMS 1.1      Power by maosin.com
'Email: maosin@163.com , maosin@maosin.com
'Web: http://www.maosin.com  http://www.maosin.net
'Copyright (C) 2006 maosin.com All Rights Reserved.
'========================================================
%>

⌨️ 快捷键说明

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