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

📄 shangpin_list.asp

📁 这是一个网上购物物网站,数据库的连接在CONN.ASP中,既有前台网站,也有后台管理
💻 ASP
字号:
<!--#include file="conn.asp"-->
<% 
bigclass=request("bigclass")
%>
<html>
<head>
<meta http-equiv="Content-Language" content="zh-cn">
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>后台</title>
<link href="image/css.css" rel="stylesheet" type="text/css">
</head>
<body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">
<div align="center"> 
  <center>
  <table width="95%" border="0" cellpadding="0" cellspacing="0">
        <% 

page=clng(request("page"))		 
Set rs=Server.CreateObject("ADODB.RecordSet") 
if bigclass="" then
sql="select * from newgoods "
else
sql="select * from newgoods where bigclass='" & bigclass & "'"
end if
rs.Open sql,conn,1,1
if rs.eof and rs.bof then
response.Write("暂时没有此类商品!")
else 
%>
        <tr> 
          <td width="6%" height="30" rowspan="2">&nbsp;</td>
          <td height="28"> </td>
          <td width="18%" align="center"></td>
        </tr>
        <tr> 
          <td height="2" colspan="2" bgcolor="#6699cc"> </td>
        </tr>
        <% 
rs.PageSize=2
if page=0 then page=1 
pages=rs.pagecount
if page > pages then page=pages
rs.AbsolutePage=page  
for j=1 to rs.PageSize 
%>
        <tr> 
          <td height="24" align="center" ></td>
          <td height="24" colspan="2" background="img/line1.gif" > <table width="100%" border="0" cellspacing="0" cellpadding="2" align="center">
  <tr> 
    <td rowspan="4" width="30%" class="table-xia"> 
      
      <div align="center">
        <table width="99" border="0" cellspacing="0" cellpadding="0" height="99">
          <tr>
            <td background="images/xt_bj.gif">
              <div align="center"><img src="upload/<%=trim(rs("img"))%>"  width=93 height="96" border=0></div>
            </td>
          </tr>
        </table>
      
      </div>
    </td>
    <td width="70%"><font color="#990000"><%=trim(rs("name"))%></font></td>
  </tr>
  <tr> 
    <td width="70%"><span class="style1">&#24066;&#22330;&#20215;:<s><font color=red><%=trim(rs("scprice"))%></font></s>
      &#20250;&#21592;&#20215;:<font color=red><%=trim(rs("hyprice"))%></font><font color=red></font></span> </td>
  </tr>
  <tr> 
    <td width="70%"><img src="image/goumai.gif" width="50" height="19" border=0>&nbsp;&nbsp;</td>
  </tr>
  <tr> 
    <td width="70%" class="table-xia"> <font color="#999999"> 
      <%if len(trim(rs("content")))>50 then
	response.write left(trim(rs("content")),50)&"...."
	else
	response.write trim(rs("content"))
	end if%>
      </font></td>
  </tr>
</table></td>
        </tr>
        <%
rs.movenext
if rs.eof then exit for
next
%>
        <tr valign="bottom"> 
            <td height="150" colspan="3" align="center" > 
          <form method=Post action="shangpin_list.asp?bigclass=<%=bigclass%>">  
              <%if Page<2 then      
    response.write "首页 上一页&nbsp;"
  else
    response.write "<a href=shangpin_list.asp?bigclass="&bigclass&"&page=1>首页</a>&nbsp;"
    response.write "<a href=shangpin_list.asp?bigclass="&bigclass&"&page=" & Page-1 & ">上一页</a>&nbsp;"
  end if
  if rs.pagecount-page<1 then
    response.write "下一页 尾页"
  else
    response.write "<a href=shangpin_list.asp?bigclass="&bigclass&"&page=" & (page+1) & ">"
    response.write "下一页</a> <a href=shangpin_list.asp?bigclass="&bigclass&"&page="&rs.pagecount&">尾页</a>"
  end if
   response.write "&nbsp;页次:<strong><font color=red>"&Page&"</font>/"&rs.pagecount&"</strong>页 "
    response.write "&nbsp;共<b><font color='#FF0000'>"&rs.recordcount&"</font></b>条记录 <b>"&rs.pagesize&"</b>条记录/页"
   response.write " 转到:<input type='text' name='page' size=4 maxlength=10 class=input value="&page&">"
   response.write " <input class=input type='submit'  value=' Goto '  name='cndok'></span></p>"     
%>
           </form>  </td> 
         
        </tr>
<% 
end if
rs.close
set rs=nothing
%>
    </table>
  </center>  
</div>  
</html>

⌨️ 快捷键说明

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