<!--#include file="conn.asp"-->
<!--#include file="check.asp"-->
<!--#include file="../inc/setup.asp"-->
<!--#include file="../inc/sql.asp"-->
<%end if%>
<HTML>
<HEAD>
<TITLE><%=homename%>-个人会员</TITLE>
<META http-equiv=Content-Type content="text/html; charset=gb2312">
<META content="MSHTML 6.00.2800.1492" name=GENERATOR>
<LINK href="../company/images/css.css" type=text/css rel=stylesheet>
</HEAD>
<BODY>
<TABLE width=768 border=0 align="center" cellPadding=10 cellSpacing=0 borderColor=#111111 style="BORDER-COLLAPSE: collapse">
  <TBODY>
    <TR>
      <TD width="96%" valign="top">
		<TABLE width=95% border=0 align="center" cellPadding=0 cellSpacing=1 bgColor=0EBDF6>
          <TBODY>
            <TR>
              <TD bgColor=#ffffff>
			  <br>
			  <table width="95%" height="27"  border="0" align="center" cellpadding="0" cellspacing="0">
                <TR>
                  <TD width=125 background="images/bt_left_bj.gif" height=27>&nbsp;&nbsp;<IMG src="images/dot1.gif" align=absMiddle>&nbsp; <STRONG class=bt_white><font color="#FFFFFF">站内消息</font></STRONG></TD>
                  <TD width=80 background="images/bt_mid_bj.gif"><IMG src="images/bt_mid.gif" ></TD>
                  <TD width=416 background="images/bt_mid_bj.gif">&nbsp;</TD>
                  <TD align=right width=53><IMG height=27 src="images/bt_more.gif" width=53 border=0></TD>
                </TR>
              </table>
                <BR>
                <table width="100%" border="0" cellspacing="0" cellpadding="0">
                    <tr>
                      <td>
					<table width="95%"  border="0" align="center" cellpadding="0" cellspacing="2" style="border:1 solid #cccccc;">
                        <tr bgcolor="#FFF2D0">
                          <td width="120" height="30" align="center" bgcolor="#EBF6FC"><span class="style6" style="color: #000000">信息发送人</span></td>
                          <td align="center" bgcolor="#EBF6FC"><span class="style6" style="color: #000000">内容标题</span></td>
                          <td width="120" align="center" bgcolor="#EBF6FC"><span class="style6" style="color: #000000">发送时间</span></td>
                          <td colspan="2" align="center" bgcolor="#EBF6FC"><span class="style6" style="color: #000000">状态</span></td>
                        </tr>
<%
	pid=Request.Cookies("admin_person_id")
	dim i,intPage,page,pre,last,filepath'定义变量
	set rs_user = server.CreateObject("adodb.recordset")'创建对象
	sql="select * from pmailbox where reid="&pid&" order by newmail ,id desc"'定义SQL语句
	rs_user.PageSize = 10 '这里设定每页显示的记录数
	rs_user.CursorLocation = 3
	rs_user.Open sql,conn,0,2,1 '这里执行你查询SQL并获得结果记录集
	if rs_user.eof and rs_user.bof then
%>
		<tr style="cursor:hand" backgroundColor='FFFFFF'>
        <td height="30" colspan="5" align="center">对不起，您的信箱内暂无信件</td>
        </tr>
<%
	else
	pre = true
	last = true
	page = trim(Request.QueryString("page"))'变量是跳转页面时的值

	if len(page) = 0 then
		intpage = 1
		pre = false
	else
		if cint(page) =< 1 then
			intpage = 1
			pre = false
		else
			if cint(page) >= rs_user.PageCount then
				intpage = rs_user.PageCount
				last = false
			else
				intpage = cint(page)
			end if
		end if
	end if
	if not rs_user.eof then
		rs_user.AbsolutePage = intpage
	end if
	for i=1 to rs_user.PageSize
	if rs_user.EOF or rs_user.BOF then exit for
%>
                        <tr style="cursor:hand" onMouseOver="this.style.backgroundColor='F0F0F0'" onMouseOut ="this.style.backgroundColor='FFFFFF'">
                          <td height="30" align="center" onClick="window.open('msnread.asp?id=<%= rs_user("id") %>','网愿科技','height=310, width=422, top=0, left=0, toolbar=no, menubar=no, scrollbars=no, resizable=no,location=no, status=no')"><%= rs_user("sendname") %></td>
                  <td align="center" onClick="window.open('msnread.asp?id=<%= rs_user("id") %>','网愿科技','height=310, width=422, top=0, left=0, toolbar=no, menubar=no, scrollbars=no, resizable=no,location=no, status=no')"><% if len(rs_user("title"))>20 then%><%=left(rs_user("title"),20)%>...<% else%><%=rs_user("title")%><%end if%>！</td>
                  <td align="center" onClick="window.open('msnread.asp?id=<%= rs_user("id") %>','网愿科技','height=310, width=422, top=0, left=0, toolbar=no, menubar=no, scrollbars=no, resizable=no,location=no, status=no')"><%=rs_user("sdate")%></td>
                  <td align="center" onClick="window.open('msnread.asp?id=<%= rs_user("id") %>','网愿科技','height=310, width=422, top=0, left=0, toolbar=no, menubar=no, scrollbars=no, resizable=no,location=no, status=no')"><% if rs_user("newmail")=0 then Response.Write("<font color=red>未读</font>") else Response.Write("已读")%></td>
                  <td align="center"><a href="msnread.asp?action=del&id=<%= rs_user("id") %>">删除</a></td>
                        </tr>
<%
	rs_user.movenext
	next
	end if
%>
                      </table>
<table width="95%" border="0" align="center" cellpadding="2" cellspacing="2" borderColorLight=#808080 borderColorDark=#ffffff>
<tr>
<%if rs_user.pagecount > 0 then%>
<td width="13%" align="left">当前页<%=intpage%>/<%=rs_user.PageCount%></td>
<%else%>
<td width="41%" align="left">当前页0/0</td><%end if%>
<td width="46%" align="right"> <a href="?page=1">首页</a>|
<%if pre then%>
<a href="?page=<%=intpage -1%>">上页</a>| <%end if%>
<%if last then%>
<a href="?page=<%=intpage +1%>">下页</a> |<%end if%>
<a href="?page=<%=rs_user.PageCount%>">尾页</a>|转到第
<select name="sel_page" onchange=javascript:location.href=this.options[this.selectedIndex].value>
<%
	for i = 1 to rs_user.PageCount
	if i = intpage then
%>
<option value="?page=<%=i%>" selected><%=i%></option>
<%else%> 
<option value="?page=<%=i%>"><%=i%></option>
<%
	end if
	next
%>
</select>页</font>
</td>
</tr>
</table>
					  <br>
					  </td>
                    </tr>
                </table>
              </TD></TR>
          </TBODY>
        </TABLE>
        <br>
      </TD>
    </TR>
  </TBODY>
</TABLE>
<%
	rs.close
	set rs=nothing
%>
</BODY>
</html>