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

📄 orderlist_checkok.asp

📁 一套很早的多用户电子商务程序
💻 ASP
字号:
<%@ language="vbscript"%>
<%response.Expires = 0%>
<!--#include file="conn.asp"--><!--#include file="Check.asp"-->

<html>
<head>
<STYLE>BODY {
	FONT-SIZE: 9pt
}
TD {
	FONT-SIZE: 9pt; LINE-HEIGHT: 150%
}
A {
	TEXT-DECORATION: none
}
A:hover {
	TEXT-DECORATION: underline
}
#hint {
	BORDER-RIGHT: green 1px solid; PADDING-RIGHT: 4px; BORDER-TOP: green 1px solid; PADDING-LEFT: 4px; Z-INDEX: 9; BACKGROUND: #d1f9a2; FILTER: Alpha(Opacity=90, FinishOpacity=50, Style=0); PADDING-BOTTOM: 4px; BORDER-LEFT: green 1px solid; WIDTH: 200px; LINE-HEIGHT: 17px; PADDING-TOP: 4px; BORDER-BOTTOM: green 1px solid; POSITION: absolute
}
</STYLE>
<title>后台管理</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
</head>
<body background="../pic/user/bg.jpg">
<div id=hint style="display:none">&nbsp;</div>
<%
Function formatdata(ti)
mt=month(ti)
dt=day(ti)
formatdata=mt&"月"&dt&"日"
end Function
set rs=server.createobject("adodb.recordset")
sqltext="select * from OrderList  Where f_pay='已汇款' and f_send='已发货' order by RegTime desc" 
rs.open sqltext,conn,1,1

dim MaxPerPage
MaxPerPage=15

'假如没有数据时
If rs.eof and rs.bof then 
   response.write "<br><br><p align='center'><font color='#ff0000'>商城中还没有已处理订单</font></p>"
End if

'取得页数,并判断用户输入的是否数字类型的数据,如不是将以第一页显示
dim text,checkpage
text="0123456789"
 Rs.PageSize=MaxPerPage
for i=1 to len(request("page"))
   checkpage=instr(1,text,mid(request("page"),i,1))
   if checkpage=0 then
      exit for 
   end if
next

If checkpage<>0 then
      If NOT IsEmpty(request("page")) Then
        CurrentPage=Cint(request("page"))
        If CurrentPage < 1 Then CurrentPage = 1
        If CurrentPage > Rs.PageCount Then CurrentPage = Rs.PageCount
      Else
        CurrentPage= 1
      End If
      If not Rs.eof Then Rs.AbsolutePage = CurrentPage end if
Else
   CurrentPage=1
End if

call list
call showpages
'显示帖子的子程序
Sub list()%>
<table width="100%" border="0"  align="center" cellpadding="0" cellspacing="3">
  <tr class=main1 bgcolor="#00CCFF"> 
    <td height="20" align="center"><font color="#FFFFFF">订单编号</font></td>
    <td align="center"><font color="#FFFFFF">处理时间</font></td>
    <td align="center"><font color="#FFFFFF">配送方式</font></td>
    <td height="20" align="center"><font color="#FFFFFF">收货人</font></td>
    <td height="20" align="center"><font color="#FFFFFF">联系电话</font></td>
    <td align="center"><font color="#FFFFFF">发货地址</font></td>
    <td height="20" align="center"><font color="#FFFFFF">订单总额</font></td>
    <td align="center"><font color="#FFFFFF">所属商家</font></td>
  </tr>
  <%
if not rs.eof then
i=0
do while not rs.eof 
%>
  <tr class=main1 bgcolor="#E8E8E8"> 
    <td align="center" height="25"><strong><font color="#0000FF"><a href="OrderList_detail.asp?ID=<%=rs("billno")%>&p_shop=<%=rs("p_shop")%>"><%=rs("billno")%></a></font></strong></td>
    <td align="center"><%=formatdata(rs("ListTime"))%> </td>
    <td align="center"><%=rs("send")%> </td>
    <td align="center"><%=rs("Name")%></td>
    <td align="center"> <%=rs("Phone")%> </td>
    <td align="center"> <a href="#" son=hint alt="..<%=rs("Address")%>.." style="behavior:url(../tit.htc)"><%=left(rs("Address"),6)%></a> 
    </td>
    <td align="center"><%=rs("amount")%> </td>
    <td align="center"><font color=#0000FF><a href="../<%=rs("p_shop")%>/" target="_blank"><%=rs("p_shop")%></a></font> 
    </td>
  </tr>
  <%
   i=i+1
   if i >= MaxPerpage then exit do
   rs.movenext
   loop
end if
%>
</table>
<%
End sub
'显示翻页的子程序
sub showpages()%>
<table border="0" cellPadding="0" cellSpacing="0" width="100%" align="center" >
  <form method=Post action='orderlist_checkok.asp'> 
  <tr>
      <td> 
        <table border="0" cellPadding="0" cellSpacing="3" width="100%" align="center">
          <tr> 
            <td width="74%" bgcolor="#00CCFF" class=main1> 
              <p align="center"> 
                <%    
   If currentpage > 1 Then
      response.write "<a href='orderlist_checkok.asp?&page="+cstr(1)+"'>首页</a><font color='#ffffff'><b>-</b></font>"  
      Response.write "<a href='orderlist_checkok.asp?page="+Cstr(currentpage-1)+"'>前页</a><font color='#ffffff'><b>-</b></font>"
   Else
      Response.write "首页<font color='#ffffff'><b>-</b></font>"
      Response.write "前页<font color='#ffffff'><b>-</b></font>"      
   End if
   
   If currentpage < Rs.PageCount Then
      Response.write "<a href='orderlist_checkok.asp?page="+Cstr(currentPage+1)+"'>后页</a><font color='#ffffff'><b>-</b></font>"
      Response.write "<a href='orderlist_checkok.asp?page="+Cstr(Rs.PageCount)+"'>尾页</a>&nbsp;&nbsp;"
   Else
      Response.write "后页-"
      Response.write "尾页&nbsp;&nbsp;"       
   End if
   Response.write "页次:" & "<font color=#FF0000>" & Cstr(CurrentPage) &  "</font>" & "<font color='#000000'>/" & Cstr(rs.pagecount) & "</font>&nbsp;"
   Response.write "<font color=#ffffff>" & Cstr(MaxPerPage) & "</font>" & "张订单/页&nbsp" & "共" & "<font color=#ffffff>" & Cstr(Rs.RecordCount) & "</font>" & "<font color='#000000'>张订单</font>&nbsp;&nbsp;"

%>
</td>
            <td width="26%" align='center' bgcolor='#00CCFF'> <font  class=main1>转到: 
              <input type='text' name='page' size=4 maxlength=4 class=smallInput value="<%=Currentpage%>">
<input class=buttonface type='submit'  value='Go'  name='cndok' style='background-color: #E6E4C4'></span>

            </td>
        </tr>
      </table>
      </td>
  </tr>
  </form>
</table>
<%end sub
rs.close
conn.close
%>
</body>
</html>

⌨️ 快捷键说明

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