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

📄 pl.asp

📁 本系统是一套开源WEB的网站管理系统
💻 ASP
字号:
<!--#include file="include/ms_setting.asp"-->
<!--#include file="include/ms_ubb.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 catTitle:catTitle="查看全部评论"%>
<!--#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>
<tr><td valign="top" width="*">
<%
id=request.querystring("id")
pltype=request.QueryString("pltype")
select case pltype
	case "news"
		datatable="ms_news_pl"
	case "art"
		datatable="ms_art_pl"
	case "pic"
		datatable="ms_pic_pl"
	case "down"
		datatable="ms_down_pl"
	case "res"
		datatable="ms_res_pl"
	case "video"
		datatable="ms_video_pl"
end select
Select Case Request.QueryString("action")
	Case "maosin_apl"
		call addpl(datatable)
	Case else
		Call showplBody()
End Select
%>
</td></tr></table>
<!--#include file="ms_end.asp"-->
<%
Sub addpl(datatable)
If Request.form("addplsu")<>"" Then
	pl_id=trim(Request.Form("id"))
	pl_name=trim(Request.Form("pl_name"))
	pl_fen=trim(Request.Form("fen"))
	pl_content=trim(Request.Form("pl_content"))
	ms_getcode=trim(request.Form("ms_getcode"))
	dim errormsg,bool
	if ms_iscode=1 then
		if IsNumeric(ms_getcode)=false then
			showmsg "验证码为空或者输入有误","出错信息"
			exit sub
		elseif cint(ms_getcode)<>cint(session("code")) then
			showmsg "您输入的验证码和系统产生的不一相样,"&session("code")&"请重新输入","出错信息"
			exit sub
		end if
	end if
	if ms_submit=0 then
		if chkIsOut=false then
			showmsg "<font color=""#ff0000"">茂盛系统返回如下信息:</font><br><br>对不起,本站不允许从外部提交数据","系统出错信息"
			exit sub
		end if
	end if
	if pl_name="" then
		errormsg=errormsg&"<li>请输入您的姓名</li>"
	end if
	if len(pl_name)<4 or len(pl_name)>12 then
		errormsg=errormsg&"<li>您输入的姓名少于4个字符或者大于12个字符</li>"
	elseif chkIsAvaStr(pl_name)=false then
		errormsg=errormsg&"<li>用户名含有非法字符</li>"
	end if
	if isInteger(pl_id)=false then
		errormsg=errormsg&"<li>您输入id参数出错,参数应为数字整形</li>"
	end if
	if isInteger(pl_fen)=false then
		errormsg=errormsg&"<li>您输入的分数不正确,分数应为数字整型</li>"
	elseif cint(pl_fen)>100 or cint(pl_fen)<0 then
		errormsg=errormsg&"<li>您输入的分数过大或过小</li>"
	end if
	if pl_content="" then
		errormsg=errormsg&"<li>评论内容不能为空</li>"
	end if
	if len(pl_content)<4 or len(pl_name)>150 then
		errormsg=errormsg&"<li>您输入的评论内容超出了最大限制</li>"
	end if
	pl_name=chkFormStr(pl_name)
	pl_content=filterKeyWord(ubbcode(pl_content,1,1,1,1))
	if errormsg="" then
		sql="insert into "&datatable&"(id,pl_name,pl_content,pl_fen,pl_date,pl_ip) values("&pl_id&",'"&pl_name&"','"&pl_content&"',"&pl_fen&",'"&Now&"','"&getIp()&"')"
		conn.Execute sql
		showmsg "<li>评论提交成功,感谢您的参与!</li><br><br><li>三秒钟后自动返回</li><meta http-equiv='refresh' content='3;url="&request.servervariables("HTTP_REFERER")&"'>","评论提交成功"
	else
		response.write(checkstr(pl_name,bool,1,true))
		showmsg "<font color=#ff0000>系统发生了以下的错误:</font><br><br>"&errormsg,"系统信息"
	end if
End if
End Sub
Sub showplBody()
sql="select * from "&datatable&" where id="&id&" order by pl_date desc"
set rs=server.createobject("ADODB.RecordSet")
rs.open sql,connstr,1,1
rs.pagesize=30	
%>
<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>→查看全部评论</span></td><td class="rtr"></td></tr></table>
<table width="100%" height="100%" border="0" cellpadding="0" cellspacing="0" class="td_tb">
  <tr> 
    <td height="60" valign="middle" align="center"><b><%=request.querystring("title")%></b></td>
  </tr>  
  <tr> 
    <td height="40" style="padding:10px;word-break:break-all;">
	<%
	Do While Not rs.Eof and line<=rs.pagesize
		Response.Write("<span><img src=images/pl_1.gif align=absmiddle>"&rs("pl_name")&" &nbsp; &nbsp;打分:<font color=""#ff0000"">"&rs("pl_fen")&"</font> &nbsp; &nbsp;  发表时间:"&rs("pl_date")&" [来自:"&rs("pl_ip")&"]</span><BR>")
		Response.write("<span class='plLine'>"&rs("pl_content")&"</span><BR>")
		rs.MoveNext
		line=line+1
	Loop
	%></td>
  </tr>
  <tr> 
    <td class="aboutTitle">∷发表评论∷</td>
  </tr>
  <tr> 
    <td height="66" valign="top"><%Call plModule()%></td>
  </tr>
</table>
<%End Sub
'========================================================
'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 + -