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

📄 newarrivals.asp

📁 上海购物网设计的购物系统是基于WEB开发的大型购物系统。   它以构建电子商务网站为目标
💻 ASP
字号:
<!--#include file="conn.asp"-->
<!--#include file="config.asp"-->
<title><%=webname%>--新品上架</title>
<link href="images/css-1.css" rel="stylesheet" type="text/css">
<!--#include file="include/header.asp"-->
<TABLE width=778 border=0 align=center cellPadding=0 cellSpacing=0>
  <TBODY>
    <TR> 
      <TD height=5></TD>
    </TR>
  </TBODY>
</TABLE>
<TABLE cellSpacing=0 cellPadding=0 width=778 align=center border=0>
  <TBODY>
    <TR> 
      <TD class=bg3 vAlign=top width=595><TABLE cellSpacing=0 cellPadding=0 width="595" border=0>
          <TBODY>
            <TR background="images/skin/default/service.gif"> 
              <TD height=29 colspan="2" class=bg2> <table width="115" border="0" cellspacing="0" cellpadding="0">
                  <tr> 
                    <td height="29" background="images/skin/default/logoo.gif"><div align="center"><FONT COLOR="#FFFFFF"><FONT COLOR="#000000"> 
                        &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<strong><font color="<%=bgclr1%>">精品热卖</font></strong></FONT></FONT></div></td>
                  </tr>
                </table>
                
              </TD>
            </TR>
            <TR valign="top"> 
              <TD width="1" background="images/skin/login_02.gif">&nbsp;</TD>
              <TD><TABLE WIDTH="590" BORDER="0" CELLSPACING="0" CELLPADDING="0" ALIGN="CENTER">
                  <tr> 
                    <td colspan="2" align="center" valign="middle" bgcolor="#FFFFFF">&nbsp;</td>
                    <td width="1" height="16" bgcolor="#FFFFFF">&nbsp;</td>
                  </tr>
                  <TR> 
                    <TD HEIGHT="200" colspan="2" VALIGN="TOP" BGCOLOR=<%=bgclr3%>> 
                      <%
				Const MaxPerPage=8
   				dim totalPut   
   				dim CurrentPage
   				dim TotalPages
   				dim j
   				dim sql
    			if Not isempty(request("page")) then
      				currentPage=Cint(request("page"))
   				else
      				currentPage=1
   				end if 
		 set rs=server.CreateObject("adodb.recordset")
		  rs.open "select id,prename,name,company,mark,intro,introduce,predate,productdate,pretype,type,viewnum,price,price1,price2,other,grade,discount,pic from product where isfb=0 and iscx=1 order by adddate desc",conn,1,1
		  
				if err.number<>0 then
				response.write "<p align='center'>数据库中暂时无数据</p>"
				end if
				
  				if rs.eof And rs.bof then
       				Response.Write "<p align='center'> 对不起,目前还没有这种商品!</p>"
   				else
	  				totalPut=rs.recordcount

      				if currentpage<1 then
          				currentpage=1
      				end if

      				if (currentpage-1)*MaxPerPage>totalput then
	   					if (totalPut mod MaxPerPage)=0 then
	     					currentpage= totalPut \ MaxPerPage
	   					else
	      					currentpage= totalPut \ MaxPerPage + 1
	   					end if
      				end if

       				if currentPage=1 then
            			showContent
            			showpage totalput,MaxPerPage,"newarrivals.asp"
       				else
          				if (currentPage-1)*MaxPerPage<totalPut then
            				rs.move  (currentPage-1)*MaxPerPage
            				dim bookmark
            				bookmark=rs.bookmark
            				showContent
             				showpage totalput,MaxPerPage,"newarrivals.asp"
        				else
	        				currentPage=1
           					showContent
           					showpage totalput,MaxPerPage,"newarrivals.asp"
	      				end if
	   				end if
   				   				end if

   				sub showContent
       			dim i
	   			i=0

			%>
                      <%do while not rs.eof%>
                      <TABLE WIDTH="96%" BORDER="0" ALIGN="center" CELLPADDING="2" CELLSPACING="2">
                        <TR> 
                          <TD WIDTH="20%" ROWSPAN="7" align="center"> <TABLE WIDTH="90" HEIGHT="96" BORDER="0" CELLPADDING="0" CELLSPACING="1" BGCOLOR="#cccccc">
                              <TR> 
                                <TD WIDTH="90" BGCOLOR="#FFFFFF" align="center"> 
                                  <a href=product.asp?id=<% = rs("id") %> target="_blank"> 
                                  <% if trim(rs("pic"))<>"" then %>
                                  <img src=<% = trim(rs("pic"))%> width="<% = webimg9 %>"  height="<% = webimg10 %>" border=0 ></a> 
                                  <%  else %>
                                  <img src=images/skin/default/emptybook.jpg width="100" height="100"  border=0> 
                                  <% end if %>
                                </TD>
                              </TR>
                            </TABLE></TD>
                          <TD COLSPAN="3"><%=trim(rs("prename"))%><A HREF=product.asp?id=<%=rs("id")%>><font color="#FF0000"><%=trim(rs("name"))%></font></A></TD>
                        </TR>
                        <TR> 
                          <TD><%=trim(rs("company"))%><%=trim(rs("mark"))%></TD>
                          <TD colspan="2"><%=trim(rs("intro"))%><%=trim(rs("introduce"))%></TD>
                        </TR>
                        <TR> 
                          <TD width="20%">浏览次数:<%=trim(rs("viewnum"))%></TD>
                          <TD width="20%"><%=trim(rs("pretype"))%><%=trim(rs("type"))%></TD>
                          <TD width="20%"><%=trim(rs("other"))%><%=trim(rs("grade"))%></TD>
                        </TR>
                        <TR> 
                          <TD><%=trim(rs("price"))%><%=rs("price1")%>元</TD>
                          <TD>会 员 价:<font color="#FF0000"><%=rs("price2")%>元</font></TD>
                          <TD>节  省:<font color="#FF0000"><%=rs("price1")-rs("price2")%></font>元</TD>
                        </TR>
                        <tr> 
                          <td COLSPAN="3" height="5"></td>
                        </tr>
                        <tr> 
                          <TD colspan="2"><div align="center"><a href=# onClick="javascript:window.open('cart.asp?id=<% = rs("id") %>','','width=630,height=350,toolbar=no, status=no, menubar=no, resizable=yes, scrollbars=yes');return false;"><img src=images/skin/default/cart.gif width=50 height=19 align=absmiddle border=0></a></div></TD>
                          <TD><a href=# onClick="javascript:window.open('addto.asp?id=<% = rs("id") %>&action=add','','width=630,height=350,toolbar=no, status=no, menubar=no, resizable=yes, scrollbars=yes');return false;"><img src=images/skin/default/addto.gif width=50 height=19 align=absmiddle border=0></a></TD>
                        </TR>
                      </TABLE>
                      <table height=1 cellspacing=0 cellpadding=0 width=500 
                        align=center bgcolor=#f2f2f2 border=0 valign="top">
                        <tbody>
                          <tr> 
                            <td></td>
                          </tr>
                        </tbody>
                      </table>
                      <%i=i+1
			if i>=MaxPerPage then Exit Do
			rs.movenext
			loop
			rs.close
			set rs=nothing%>
                      <%  
				End Sub   
  
				Function showpage(totalnumber,maxperpage,filename)  
  				Dim n
  				
				If totalnumber Mod maxperpage=0 Then  
					n= totalnumber \ maxperpage  
				Else
					n= totalnumber \ maxperpage+1  
				End If %>
                      <form method=Post action=<%=filename%>>
                        <p align="center"> 
                          <%
				If CurrentPage<2 Then  %>
                          首 页 上一页 
                          <% Else  %>
                          <a href=<% = filename %>?page=1>首 页</a> <a href=<% = filename %>?page=<% = CurrentPage-1 %>>上一页</a> 
                          <% End If 
				If n-currentpage<1 Then  %>
                          下一页 末 页 
                          <%  Else  %>
                          <a href=<% = filename %>?page=<% = (CurrentPage+1) %>>下一页</a> 
                          <a href=<% = filename %>?page=<% = n %>>末 页</a> 
                          <% End If  %>
                          第 <b> 
                          <% = CurrentPage %>
                          </b> 页 共 <b> 
                          <% = n %>
                          </b> 页 共&nbsp;<b> 
                          <% = totalnumber %>
                          </b>&nbsp;件商品  转到第: 
                          <input type='text' name='page' size=2 maxlength=10 class=smallInput value=<% = currentpage %>>
                          <input type='submit'  class='contents' value='跳转' name='cndok'>
                      </form>
                      <%
				End Function  
			%>
                    </TD>
                  </TR>
                </TABLE></TD>
            </TR>
            <TR> 
              <TD height=1 colSpan=2 bgColor=<%=bgclr1%>></TD>
            </TR>
            <TR> 
              <TD colSpan=2></TD>
            </TR>
        </TABLE></TD>
      <TD width=183 vAlign=top background=images/skin/default/product_02.gif> 
        <TABLE cellSpacing=0 cellPadding=0 width=183 border=0>
          <TBODY>
            <TR> 
              <TD height="25" background="images/search_02.gif"><img src="images/skin/default/product_03.gif" width="183" height="25"></TD>
            </TR>
            <TR> 
              <TD height=20> 
                <!--#include file="include/pronav.asp"-->
              </TD>
            </TR>
          </TBODY>
        </TABLE>
      </TD>
    </TR>
    <TR bgColor=<%=bgclr1%>> 
      <TD height=5 colSpan=2></TD>
    </TR>
  </TBODY>
</TABLE>
<!--#include file="include/footer.asp"--> 

⌨️ 快捷键说明

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