 <?php  include("../template/usertop.php");?>
<body>
<?php  include("../template/menu.php");?>
<div class="head-wrap">
<div class="main_top_1">
<div class="mt" style="position:relative;">
<?php  include("../template/user_left.php");?> 
<div class="user_zx_right">
<div class="box">
<div class="tagMenu">
<ul class="menu">
<li class="current"><a href="/user/msg.php">站内短信</a></li>
<li><a href="/user/login_log.php">登录记录</a></li>
</ul>
<div class="hite"> <span id="account"></span> </div>
</div>
</div>
<div class="myinfo" style="padding: 20px; margin-bottom: 15px;background:#fff;">
<p style="margin:15px 0px;">尊敬的<?php echo configW('webname'); ?>会员，以下是您在<?php echo configW('webname'); ?>的站内短信，敬请审阅！</p>

<div class="container-fluid">
        <div class="row-fluid">
            <table class="table table-striped table-bordered table-hover datatable">
                <thead>
                    <tr>
                        <th><img src="/public/Front/user/xf1.jpg"></th>
                        <th>标题</th>
                        <th>时间</th>
                        <th>状态</th>
                        <th>删除</th>
                    </tr>
                </thead>
                <tbody>
					<?php
						$username = $_SESSION["glo_username"];
						$sql="select * from {$db_prefix}member_msg where username = '{$username}' order by id desc limit 20";
						$rs = $db->query($sql);
						if(mysql_num_rows($rs) <1 ){  ?>
							<tr>
								<td width="90%" colspan="5">暂无记录</td>
							</tr>
					<?php }else{ 
						while ($rs2=$db->fetch_array($rs)){  ?>
                    <tr class="odd gradeX" onclick="$(&quot;#sms<?php echo $rs2['id']; ?>,#msg<?php echo $rs2['id']; ?>&quot;).slideToggle(&quot;slow&quot;);user_msg(&quot;<?php echo $rs2['id']; ?>&quot;);">
                        <td><?php echo $rs2['id']; ?></td>
                        <td><img src="/public/Front/user/read.jpg"> <?php echo $rs2['title']; ?></td>
                       <td><?php echo toData($rs2['posttime']); ?></td>
                        <td class="center" id="zt<?php echo $rs2['id']; ?>"><font color="#00A11D"><?php echo $rs2['status']?'已读':'未读'; ?></font></td>
                        <td class="center"  id="del<?php echo $rs2['id']; ?>"><a onclick="user_msg_del(&quot;<?php echo $rs2['id']; ?>&quot;)">删除</a></td>
                    </tr>
                    <tr>
						<td height="34" style="height:auto;font-size:12px;border-left:#e6e6e6 solid 1px;border-bottom:#e6e6e6 solid 1px;border-right:#e6e6e6 solid 1px; padding:5px;display:none;" colspan="5" id="sms<?php echo $rs2['id']; ?>"><div style="width:100%; display:none;" id="msg<?php echo $rs2['id']; ?>"><?php echo $rs2['content']; ?></div></td>
					</tr>
                    <?php  }}  ?>
                </tbody>
            </table>
        </div>
    </div> 
</div>
</div>
</div>
</div>
<?php  include("../template/foot.php");?>
<?php  include("../template/page.php");?>
</body></html>