?? dlmx.asp
字號:
<!-- #include file="include/adovbs.inc" -->
<!-- #include file="include/dataconn.asp" -->
<!-- #include file="include/checksession.asp" -->
<!-- #include file="common.asp" -->
<%
Response.Buffer =false
Response.Expires=-1
thistoday =year(now)&"-"&month(now)&"-"&day(now)
dtfrom=trim(request("dtfrom"))
dtto=trim(request("dtto"))
if len(dtfrom)=0 then
dtfrom=year(now)&"-"& month(now)&"-1"
dtfrom=cstr(dtfrom)
dtfrom=datevalue(dtfrom)
end if
if len(dtto)=0 then
dtto=cstr(thistoday)
dtto=datevalue(dtto)
end if
set HyRs=server.CreateObject("adodb.recordset")
sql = "SELECT * FROM dlclub"
sql =sql & " where regtime between #"&dtfrom&"# and #"&dtto&"#"
'sql =sql & " group by hid order by AllMoney desc"
HyRs.Open sql,conn
j=HyRs.RecordCount
%>
<html>
<head>
<meta NAME="GENERATOR" Content="Microsoft Visual Studio 6.0">
<META http-equiv=Content-Type content="text/html; charset=gb2312">
<link rel="stylesheet" href="include/e1.css" type="text/css">
<script>
function fPopUpCalendarDlg(ctrlobj)
{
showx = event.screenX - event.offsetX - 4 - 210 ; // + deltaX;
showy = event.screenY - event.offsetY + 18; // + deltaY;
newWINwidth = 210 + 4 + 18;
retval = window.showModalDialog("Include/CalendarDlg.htm", "", "dialogWidth:197px; dialogHeight:210px; dialogLeft:"+showx+"px; dialogTop:"+showy+"px; status:no; directories:yes;scrollbars:no;Resizable=no; " );
if( retval != null ){
ctrlobj.value = retval;
}else{
//alert("canceled");
}
}
</script>
</head>
<body leftmargin="10" topmargin="10" marginwidth="0" marginheight="0">
<form method="post" action="dlmx.asp" id="form1" name="form1">
<table width="100%" border="0" height="21" cellpadding="0" cellspacing="0">
<tr>
<td width="76%"> <div align="center"><font color="#FFFFFF"><font color="#000000">從</font></font>
<input id="dtfrom" name="dtfrom" readonly value="<% =dtfrom %>" size="12">
<img src="image/datetime.gif" style="cursor:hand;" align="absmiddle" alt="彈出日歷下拉菜單" onClick="fPopUpCalendarDlg(document.form1.dtfrom);return false" width="16">
到
<input id="dtto" name="dtto" readonly value="<% =dtto %>" size="12">
<img src="image/datetime.gif" style="cursor:hand;" align="absmiddle" alt="彈出日歷下拉菜單" onClick="fPopUpCalendarDlg(document.form1.dtto);return false" width="16">
<input type="image" value="submit" src="Image/027.gif" id="image1" name="image1">
</div></td>
<td width="24%"> </td>
</tr>
</table>
</form>
<%
if j>0 then
dim i
i=1
const pagesize=100
HyRs.PageSize = pagesize
total=HyRs.PageCount
pageno=Request("pageno")
if pageno="" then pageno=1
if not isnumeric(pageno) and pageno<>"" then
%>
<script>alert("請輸入正確的頁碼");
window.history.back();</script>
<%Response.End
End if
if (pageno-1)*pagesize>=j then
if (j mod pagesize)=0 then
pageno= j \ pagesize
else
pageno= j \ pagesize + 1
end if
end if
if pageno<1 then
%>
<script>alert("頁碼數不能小于1");
window.history.back();</script>
<%Response.End
End if
if (pageno>65535) then
%>
<script>alert("頁碼數不能大于總數!");
window.history.back();</script>
<%Response.End
end if
if (clng(pageno)>clng(total)) then %>
<script>alert("頁碼數不能大于總數!");
window.history.back();</script>
<%
Response.End
end if
pageno=cint(pageno)
%>
<table border="1" cellpadding="0" cellspacing="0" width="98%" bordercolordark="#e0f4ff" bordercolorlight="#162d6b">
<tr class="td3">
<td width="60" height="26"> <div align="center"><FONT color=#ffffff>會員帳號</FONT></div></td>
<td width="57" height="26"> <div align="center"><FONT color=#ffffff>編號</FONT></div></td>
<td width="75" height="26" align="center"> <FONT color=#ffffff>姓名</FONT></td>
<td width="76" height="26"> <div align="center"><FONT color=#ffffff>推薦人帳號</FONT></div></td>
<td width="124" height="26" align="center"> <FONT color=#ffffff>申請時間</FONT></td>
<td width="109" height="26"> <div align="center">
<DIV align=center><FONT color=#ffffff>審核時間</FONT></DIV></div></td>
<td width="68" height="26">
<DIV align=center><FONT color=#ffffff>報單數</FONT></DIV></td>
<td width="74" height="26" align="center"> <FONT color=#ffffff>報單費用</FONT></td>
<td width="80" height="26" align="center"> <FONT color=#ffffff>累計報單數</FONT></td>
<td width="96" height="26" align="center"> <FONT color=#ffffff>累計報單費用</FONT></td>
<td width="65" height="26" align="center"> 報單獎金</td>
<td width="67" height="26" align="center"> 當前余額</td>
</tr>
<%
HyRs.absolutepage=pageno
dim x
i=1
x=2
while (not HyRs.eof) and (i<=pagesize)
if x mod 2 then
%>
<tr class="td1">
<%
else
%>
<tr height="25">
<%
end if
%>
<td height="24"> <div align="center">
<%set hh=conn.execute("select * from hyclub where id="&hyrs("hid")&"")
response.write hh("hynumber")
hh.close
set hh=nothing%>
</div></td>
<td height="24"><div align="center">
<%=HyRs("id")%> </div></td>
<td height="24" align="center"><%=hyrs("dlname")%></td>
<td height="24"><div align="center"> <%set hh=conn.execute("select * from hyclub where id="&hyrs("tid")&"")
response.write hh("hynumber")
hh.close
set hh=nothing%> </div></td>
<td height="24" align="center"><%=hyrs("regtime")%></td>
<td height="24"> <div align="center">
<% =HyRs("checktime")%>
</div></td>
<td height="24" align="center"> <%set dll=conn.execute("select count(*) as counts from orders where dlid="&hyrs("hid")&"")
if not dll.eof then response.write dll("counts")
dll.close
set dll=nothing%>
</td>
<td height="24" align="center"><%set dll=conn.execute("select * from orders where dlid="&hyrs("hid")&"")
if dll.eof then
else
counts=dll.recordcount
all=dll("price")*counts
response.write all
end if
dll.close
set dll=nothing%> </td>
<td height="24" align="center"> <%=hyrs("orders")%> </td>
<td height="24" align="center"> <%=hyrs("orders")*hyrs("oprice")%> </td>
<td height="24" align="center"> <%=hyrs("orders")*10%></td>
<td height="24" align="center"> <%=hyrs("allmoney")%> </td>
</tr>
<%
HyRs.movenext
i=i+1
x=x+1
wend %>
<%
else
Response.Write "報單還沒有計算!<a href='javascript:history.back()'>返回</a>"
end if%>
</table>
<p></p>
<%if j>0 then%>
<table align="center">
<tr>
<form name="thisform1" method="Post" action="dlmx.asp?findcontent=<%=content%>">
<td>到第
<input type="text" name="pageno" value="<% =pageno%>" size="3">
頁<a onclick="javascript:thisform1.submit();">GO</a> </font></td>
</form>
<td>第
<% =pageno %>頁
/共
<% =total%>
頁</font></td>
<% if pageno<=1 then %>
<td><font color="#cccccc">首頁</font></td>
<td><font color="#cccccc">上一頁</font></td>
<% else %>
<td><a href="dlmx.asp?pageno=1&findcontent=<%=content%>"><font face="Webdings" color="#FFFFFF">9</font>首頁</font></a></td>
<td><a href="dlmx.asp?pageno=<%=pageno-1%>&findcontent=<%=content%>">上一頁</font></a></td>
<%end if%>
<% if pageno>=total then %>
<td><font color="#cccccc">下一頁</font></td>
<td><font color="#cccccc">尾頁</font></td>
<%else%>
<td><a href="dlmx.asp?pageno=<%=pageno+1%>&findcontent=<%=content%>">下一頁</font></a></td>
<td><a href="dlmx.asp?pageno=<%=total%>&findcontent=<%=content%>">尾頁</font></a></td>
<% end if%>
</tr>
</table>
<%end if%>
</body>
</html>
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -