
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>我的订单_<%=TD_home%></title>
<meta name="keywords" content="<%=TD_keywords%>" />
<meta name="description" content="<%=TD_description%>" />
</head>
<!--#include file="css_js.html" --><body>
<!--#include file="top.html" -->
<div class="wrapper col2">
<div id="breadcrumb">
    <ul>
      <li class="first"><%=TD_home%></li>
      <li>&#187;</li>
      <li><a href="<%=TD_url%>">首页</a></li>
      <li>&#187;</li>
      <li> <a href="/my_orders/?1-1.html">我的订单</a></li>
    </ul>
  </div></div>
  <div class="wrapper col3">
  <div id="container" class="clear">
    <!-- ####################################################################################################### -->
    <div id="content">
      <h1>我的订单</h1>
      <p><%if session("username")<>"" then%>
<%	
set rs=server.createobject("adodb.recordset") 
exec="select * from [orders] where userid="&session("username")&" order by id desc "  
rs.open exec,conn,1,1 
if rs.eof then
response.Write "&nbsp;暂无订单！"
else
rs.PageSize =15 '每页记录条数
iCount=rs.RecordCount '记录总数
iPageSize=rs.PageSize
maxpage=rs.PageCount 
page=b
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	
%>
<%For i=1 To x%>
<table width="100%" border="0" align="center" cellpadding="3" cellspacing="0">
  <tr>
    <td width="42%" height="30">订单编号：<a href="/orders/?<%=rs("id")%>-1.html"><%=rs("OrderNo")%></a></td>
    <td width="39%">时间：<%=rs("data")%></td>
    <td width="19%">订单状态：<%
	if rs("state")=1 then
	response.write("<font color=#FF0000>未处理</font>")
	else
	response.write("已处理")
	end if
	%></td>
  </tr>
</table>
<%rs.movenext
next
end if
%>
<%'以下显示分页
 call PageControl(iCount,maxpage,page,"border=0 align=center","<p align=center>")
rs.close
set rs=nothing
%>
<%
else
response.write ("<div style="" padding:20px;font-size:14px; color:#990000; font-weight:bold; text-align:left"">您未登陆！请先登陆</div>")
response.write("<a href=""/member/login.asp"" style="" padding:20px;font-size:14px; color:#000000; text-align:left"">已注册会员请点此登陆！</a>")
response.write("<a href=""/member/Register.asp"" style="" padding:20px;font-size:14px; color:#000000; text-align:left"">还没有帐号？点击此处进行注册！</a>")
end if
%></p>
</div>
    <div id="column">
      <div class="subnav">
        <h2>栏目导航</h2>
        <ul> <!--#include file="member_right.html" -->
         
        </ul>
      </div>
      
      <!--#include file="index_right.html" -->
      
    </div>
    <!-- ####################################################################################################### -->
  </div>
</div>
<!--#include file="foot.html" -->
</body>
</html>

