基于ASP的SQL小区物业管理系统课程设计
源代码在线查看: bbs_do.asp
dim title,content,ntime,username,n,m
title=Server.HTMLEncode(Request.Form("title"))
content=Request.Form("content")
'Response.Write content
content=replace(content,chr(13)," ") '回车,
'content=left(content,len(content)-3)
'Response.Write("")
'Response.Write content
'Response.End()
m=Request.Form("RadioGroup")
ntime=now()
username=session("username")
if m="" then
randomize()
n=replace(mid(rnd(),3,1),"0","1")
else
n=m
end if
%>
set cmd=Server.CreateObject("ADODB.COMMAND")
cmd.ActiveConnection=conn
cmd.CommandText="insert into tbmessage values('"&username&"','"&title&"','"&content&"','"&ntime&"',0,"&n&")"
cmd.execute
Response.Redirect("bbs.asp")
%>