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

📄 pubnewslist.asp

📁 一个不错的个人商务网站的源码
💻 ASP
字号:
<!--#include file="db_conn.asp"-->
<!--#include file="comm/comm.asp"-->
<!--#include file="comm/sub.asp"-->
<!--#include file="comm/pages.asp" -->
<!--begin TOP-->
<%
'说明 head(a,b,c)
'a为页标题
'b为页描述
'c为页关键字
call head(r(26)&"-网站公告列表",r(27),r(28))
%>
<!--end TOP-->
<div align="center">
<table border="0" width="760" cellpadding="0" style="border-collapse: collapse">
	<tr>
		<td width="182" valign="top"><!--#include file="left.asp"--></td>
		<td width="15" valign="top"> </td>
		<td width="563" valign="top">
	
		<table border="0" width="563" id="table1" cellpadding="0" style="border-collapse: collapse">
			<tr>
				<td width="72" class="topmanu_bg" height="20">
				<p align="center">
				<img border="0" src="images/icon_bulletin.gif" width="16" height="16" align="absmiddle">公告列表</td>
				<td width="490" height="13">
				<p align="left">&nbsp;</td>
			</tr>
			<tr>
				<td width="563" colspan="2" class="right_nav" height="3"></td>
			</tr>
		</table>
		<table border="0" width="100%" id="table5" cellpadding="0" style="border-collapse: collapse">
			<tr>
				<td> </td>
			</tr>
		</table>
		<table border="0" width="100%" id="table2" cellpadding="4" style="border-collapse: collapse">
	<%
	set rs=server.CreateObject("adodb.recordset")
	sql="select id,title,flag,addtime from info_list order by addtime desc"
	rs.open sql,conn,1,1
	if (rs.eof and rs.bof) then
	response.write "<tr>"
    response.write "<td width=500 colspan=4><font color=#FF0000>您还没有收藏的商品</font></td>"
    response.write "</tr>"
    else
    rs.PageSize =20 '每页记录条数
			iCount=rs.RecordCount '记录总数
			iPageSize=rs.PageSize
    		maxpage=rs.PageCount 
    		page=request("page")
    
    if Not IsNumeric(page) or page="" then
        page=1
    else
        page=cint(page)
    end if
    
    if page<1 then
        page=1
    elseif  page>maxpage then
        page=maxpage
    end if
    
    rs.AbsolutePage=Page

	if page=maxpage then
		x=iCount-(maxpage-1)*iPageSize
	else
		x=iPageSize
	end if

end if
						  ii=1
						  while not rs.eof and ii<=rs.pagesize
						  set id=rs("id")
						  set title=rs("title")
						  set flag=rs("flag")
						  set addtime=rs("addtime")
						  %>
			<tr>
				<td>·<a href="ad/pubNewsDetail.asp?id=<%=id%>"><font color="<%=flag%>"><%=title%></font></a><font color="#808080">(发布时间:<%=addtime%> )</font></td>
			</tr>
				<%
rs.movenext
ii=ii+1
wend
%>
			</table>
		<table border="0" width="100%" id="table4" cellpadding="0" style="border-collapse: collapse">
			<tr>
				<td><%call PageControl(iCount,maxpage,page,"border=0 align=right","<p align=right>")%></td>
			</tr>
		</table>
		

		</td>
	</tr>
</table>
</div>
<!--begin end-->
<%call boot()%><!--end end-->

⌨️ 快捷键说明

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