<!--#include file="../Include/Conn.asp" -->
<!--#include file="../Include/const.asp" -->
<!--#include file="../Include/function.asp" -->
<% uname=session("puid") 
Set rs = Server.CreateObject("ADODB.Recordset")
sql="select * from pmailbox where reid='"&uname&"'and newmail=0"
rs.open sql,conn,1,1
mailnum=rs.recordcount
rs.close                                                                    
set rs=nothing
Set rs = Server.CreateObject("ADODB.Recordset")
if request("del")<>"" then 
conn.Execute("delete * from pmailbox where id="&request("del"))
response.write"<SCRIPT language=JavaScript>alert('信件删除成功！请刷新登陆页');"
response.write"javascript:window.close();</SCRIPT>" 
response.end 
end if
sql="select * from pmailbox where id="&request("id")
rs.open sql,conn,1,1
if rs.bof or rs.eof then
response.write"<SCRIPT language=JavaScript>alert('信件不存在或已被删除！');"
response.write"javascript:window.close();</SCRIPT>"
response.end
end if
newmail=rs("newmail") %>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD><TITLE><%=site_info(0)%></TITLE>
<META http-equiv=Content-Type content="text/html; charset=gb2312"><LINK 
href="../Include/Style1.css" type=text/css rel=stylesheet>
<META content="Microsoft FrontPage 5.0" name=GENERATOR>
<style type="text/css">
<!--
.style2 {color: #FFFFFF}
-->
</style>
</HEAD>
<!--#include file="../Include/top.asp" -->
<div align="center">
  <center>
  <table border="0" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="770" id="AutoNumber6" bgcolor="#000000" height="1">
    <tr>
      <td width="100%"></td>
    </tr>
  </table>
  </center>
</div>



<div align="center">
  <center>
  <table border="0" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="770" id="AutoNumber62" bgcolor="#FFFFFF">
    <tr>
      <td width="100%" valign="top">
      <table border="0" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="100%" id="AutoNumber64">
        <tr>
          <td width="100%">　</td>
        </tr>
      </table>
      <p>　</p>
      <div align="center">
        <center>
        <table border="1" cellpadding="8" cellspacing="0" style="border-collapse: collapse" bordercolor="#003366" width="70%" id="AutoNumber65" bgcolor="#2C8ED3">
          <tr>
            <td bgcolor="#003366" colspan="3">
            <p align="center"><font color="#FFFFFF">======&gt;&gt;&gt; 个 人 站 内 信 箱 
            &lt;&lt;&lt;======</font></td>
          </tr>
          <tr>
            <td width="19%" align="right" bgcolor="#FFFFFF">发 信 人：</td>
            <td colspan="2" bgcolor="#FFFFFF">　<%=rs("sendname")%></td>
          </tr>
          <tr>
            <td width="19%" align="right" bgcolor="#FFFFFF">信件标题：</td>
            <td colspan="2" bgcolor="#FFFFFF">　<%=rs("title")%></td>
          </tr>
          <tr>
            <td width="19%" align="right" bgcolor="#FFFFFF">发信时间：</td>
            <td colspan="2" bgcolor="#FFFFFF">　<%=rs("sdate")%></td>
          </tr>
          <tr>
            <td colspan="3" bgcolor="#FFFFFF"><br>
            <br>　　<%=rs("mailtext")%>
　</td>
          </tr>
          <tr bgcolor="#FFFFFF">
            <td colspan="3">
            <table border="0" cellpadding="4" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="100%" id="AutoNumber66">
              <tr>
                <td width="33%" align="center"><a href="viewmail.asp?del=<%=rs("id")%>">删除信件</a>　</td>
                <td width="33%" align="center"><a href="sendmail.asp?reid=<%=rs("senduid")%>">回复信件</a>　</td>
                <td width="34%" align="center"><a href="javascript:window.close()">关闭窗口</a>　</td>
              </tr>
            </table>            </td>
          </tr>
          <tr>
            <td width="19%" bgcolor="#003366">　</td>
            <td width="53%" bgcolor="#003366">　</td>
            <td width="28%" bgcolor="#003366">　</td>
          </tr>
        </table>
        </center>
      </div>
      <p>　</p>
      <table border="0" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="100%" id="AutoNumber63">
        <tr>
          <td width="100%">　</td>
        </tr>
      </table>
      </td>
    </tr>
  </table>
  </center>
</div>
<div align="center">
  <center>
  <table border="0" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="770" id="AutoNumber19" bgcolor="#111111" height="1">
    <tr>
      <td width="100%"></td>
    </tr>
  </table>
  </center>
</div>
<!--#include file="../Include/Bottom.asp" -->
</BODY></HTML>
<% rs.close                                                                    
set rs=nothing
if newmail="0" then
Set rs = Server.CreateObject("ADODB.Recordset")
sql2="update pmailbox set newmail=newmail+1 where id="&request("id")
rs.open sql2,conn,1,1
end if %>