|
<!--#include file="conn.asp"-->
<%
Response.ContentType="text/html"
Response.Charset="gb2312"
srhType=request("type")
srhKey=trim(request("key"))
if isempty(request("page")) or trim(request("page"))="" then
page=1
else
page=clng(request("page"))
end if
%>
<table width="99%" border="0" align="center" cellpadding="3" cellspacing="1" bgcolor="#666666">
<tr bgcolor="#E8F1FF" align="center">
<td>手机号码</td>
<td>短信类别</td>
</tr>
<%
set getInf=server.CreateObject("ADODB.Recordset")
getInf_sql="select * from [Note] where 1=1 "
if srhType<>"" then
getInf_sql=getInf_sql&"and dxpt_TelType="&clng(srhType)&" "
end if
if srhKey<>"" then
getInf_sql=getInf_sql&"and dxpt_TelNumber='"&srhKey&"' "
end if
getInf_sql=getInf_sql&"order by id desc"
getInf.open getInf_sql,conn,1,1
getInf.PageSize=5000
if page=0 then
page=1
end if
pages=getInf.PageCount
if page > pages then
page=pages
end if
getInf.AbsolutePage = page
for j=1 to getInf.PageSize
%>
<tr bgcolor="#FFFFFF" align="center">
<td><%=getInf("dxpt_TelNumber")%></td>
<td>
<%
set Get_TypeName=server.CreateObject("ADODB.Recordset")
Get_TypeName_Sql="select * from NoteSort where dxpt_SortID="&getInf("dxpt_TelType")
Get_TypeName.open Get_TypeName_Sql,conn,1,1
if not Get_TypeName.eof then
response.Write Get_TypeName("dxpt_SortName")
end if
Get_TypeName.close
set Get_TypeName=nothing
%> </td>
</tr>
<%
getInf.movenext
if getInf.eof then
exit for
end if
next
%>
<%
getInf.close
set getInf=nothing
%>
</table>
<%
dim fname
fname = now()
fname = replace(fname,"-","")
fname = replace(fname," ","")
fname = replace(fname,":","")
fname = replace(fname,"PM","")
fname = replace(fname,"AM","")
fname = replace(fname,"上午","")
fname = replace(fname,"下午","")
fname = int(fname) + int((10-1+1)*Rnd + 1)
response.ContentType ="application/vnd.ms-excel"
Response.AddHeader "Content-Disposition", "attachment; filename=" & fname
%>
帮忙看下 |
|