|
马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。
您需要 登录 才可以下载或查看,没有帐号?立即注册
x
ASP是依赖组件的,能访问数据库的组件好多就有好多种,再有就是你微软的工具可是什么都要收钱的啊!程序<!--#includefile="../conn/dbconn1.asp"-->
<!--#includefile="../inc/safe.asp"-->
<%
content=Replace_Text(request.Form("content"))
content=replace(content,"<","[")
content=replace(content,">","]")
newsid=Replace_Text(request.Form("newsid"))
ip=request.Form("ip")
rname=Replace_Text(request.Form("rname"))
rname=replace(rname,"<","[")
rname=replace(rname,">","]")
username=Replace_Text(request.Form("username"))
username=replace(username,"<","[")
username=replace(username,">","]")
处置宣布内容是脏话
setrs=server.CreateObject("adodb.recordset")
sql="select*frombadword"
rs.opensql,conn,3,3
ifrs.eofthen
response.Write("meiziliao!")
else
onerrorresumenext
dowhilenotrs.bofandnotrs.eof
content=replace(content,rs.fields("word").value,"**")
rname=replace(rname,rs.fields("word").value,"**")
rs.movenext
loop
endif
rs.close
setrs=nothing
setrs=server.CreateObject("ADODB.RecordSet")
sql="select*frompl"
rs.opensql,conn,3,3
rs.addnew
rs("content")=content
rs("newsid")=newsid
rs("ip")=ip
rs("rname")=rname
rs("username")=username
rs.update
rs.close
%>
<%
setrsn=server.CreateObject("adodb.recordset")
sqln="selectnewsid,plnum,plbzfromnewswherenewsid="&newsid&""
rsn.opensqln,conn,1,3
rsn("plnum")=rsn("plnum")+1
rsn("plbz")=1
rsn.update
rsn.close
%>
<script>
alert("乐成公布!")
parent.location.href="shownews.asp?newsid=<%=newsid%>"
</script>
Windows本身的所有问题都会一成不变的也累加到了它的身上。安全性、稳定性、跨平台性都会因为与NT的捆绑而显现出来; |
|