当前位置: 首页 > 图文教程 > 网络编程 > ASP > 一个BBS的源代码(二)

ASP
用ASP编写网络传呼机
用ASP+CSS实现随机背景
ASP下载系统防盗链方法
用ASP编写下载网页中所有资源的程序
Request.ServerVariables应用
解决Asp程序的Server.CreateObject错误
ASP实现TCP端口扫描的方法
源码实例:ASP实现远程保存图片
用ASP+DLL实现WEB方式修改服务器时间
ASP使用MySQL数据库全攻略
ASP+SQL Server构建网页防火墙
教程/ASP 十天学会ASP之第二天
教程/ASP 十天学会ASP之第四天
教程/ASP 十天学会ASP之第五天
教程/ASP 十天学会ASP之第六天
教程/ASP 十天学会ASP之第七天
教程/ASP 十天学会ASP之第八天
教程/ASP 十天学会ASP之第九天
教程/ASP 十天学会ASP之第十天
关于学习ASP和编程的28个观点

ASP 中的 一个BBS的源代码(二)


出处:互联网   整理: 软晨网(RuanChen.com)   发布: 2009-11-03   浏览: 25 ::
收藏到网摘: n/a

  ' 打开数据库
Set Con = Server.CreateObject("ADODB.Connection")
Con.Open "asp" , Application("ConASP_RuntimeUserName") , Application("ConASP_RuntimePassword")

Set RecBBS = Server.CreateObject("ADODB.RecordSet")
Set RecReply = Server.CreateObject("ADODB.RecordSet")
Set RecMember = Server.CreateObject("ADODB.RecordSet")


%>
<HTML>
<HEAD>
<META NAME="GENERATOR" Content="Microsoft Visual Studio 6.0">
<META HTTP-EQUIV="Content-Type" Content="text/html; charset=gb2312">
<TITLE>经验交流</TITLE>
<STYLE TYPE="TEXT/CSS">
td {
color: #ffffff;
font-size: 9pt;
}
td.menu {
color: #000000;
background-color: #f0f0d0;
font-size: 12pt;
}
input {
color: #000000;
font-size: 9pt;
border-top: 1px solid;
border-left: 1px solid;
border-right: 1px solid;
border-bottom: 1px solid;
}
select {
color: #000000;
font-size: 9pt;
border-top: 1px solid;
border-left: 1px solid;
border-right: 1px solid;
border-bottom: 1px solid;
}
textarea {
color: #000000;
font-size: 9pt;
border-top: 1px solid;
border-left: 1px solid;
border-right: 1px solid;
border-bottom: 1px solid;
}
a:link {
text-decoration: none;
}
a:visited {
text-decoration: none;
}
a:hover {
text-decoration: underline;
}
</STYLE>
</HEAD>
<BODY bgcolor=#c0c0c0>

<P>
<TABLE align=center valign=top bgColor=#d0d0d0 border=1 borderColorDark=#f0f0f0 borderColorLight=#505050 cellPadding=5 cellSpacing=0 width=600 height=400>
<TR>
<TD valign=top>
<%


Job = Request("Job")
If Job = "" Then Job = "List"

'==============================
Select Case Job
'==============================

'=============================
Case "List"
'==============================
' 显示文章
%>

<TABLE align=center border=0 cellPadding=1 cellSpacing=0 width=650>
<TR>
<TD>
<TABLE WIDTH="100%" ALIGN=center BORDER=0 CELLSPACING=0 CELLPADDING=2 BGCOLOR=#f0f0d0>
<TR>
<TD class=menu valign=top>
<A href="/">飞林庄</A>-&gt;<A href="<%= ASP_FILE_NAME %>">经验交流</A>
</TD>
<TD class=menu></TD>
<TD align=right class=menu>
<FORM action="<%= ASP_FILE_NAME %>" method=get>
<INPUT type=hidden name=Job value=List>
[<A href="<%= ASP_FILE_NAME %>?Job=Write">发表文章</A>][<A href="<%= ASP_FILE_NAME %>?Job=Apply">申请账号</A>]
<INPUT id=Keyword maxLength=20 name=Keyword size=18>
<INPUT type=Submit value=主题搜索>
</FORM>
</TD>
</TR>
</TABLE>
</TD>
</TR>
</TABLE>
<TABLE align=center bgColor=#000000 border=0 cellPadding=1 cellSpacing=1 width=650>
<%

If Request("Keyword") <> "" Then KeyWord = Request("Keyword") Else KeyWord = ""

If Request("Page") = "" Then
If IsNumeric( Session("BBS_Page") ) Then
Page = Int(Session("BBS_Page"))
Else
Page = 1
End If
Else
Page = Int(Request("Page"))
End If
If Page &