<form action="" method="post">
<script language="javascript">
function do_select()
{
	 var box_l = document.getElementsByName("deid[]").length;
	 for(var j = 0 ; j < box_l ; j++)
	 {
	  	if(document.getElementsByName("deid[]")[j].checked==true)
	  	  document.getElementsByName("deid[]")[j].checked = false;
		else
		  document.getElementsByName("deid[]")[j].checked = true;
	 }
}
</script>
<div class="admin_right_top"><{$lang.inbox}></div>
<table class="admin_table tab-list">
    <tr class="sheader"> 
        <td width="20"><input type="checkbox" onclick="do_select();" /></td>
        <td><{$lang.topics}></td>
        <td width="150"><{$lang.from_to}></td>
        <td width="120"><{$lang.date}></td>
    </tr>
	<{foreach item=list from=$re.list}>
	<tr> 
        <td>
            <input type="checkbox" name="deid[]" value="<{$list.id}>" />
        </td>
        <td class="al">
            <{if !$list.iflook}>
                <img align="absmiddle" src="image/default/user_admin/unred.gif" width="16" height="14" />
            <{elseif $list.iflook==3}>
                <img align="absmiddle" src="image/default/user_admin/replied.gif" width="16" height="14" />
            <{elseif $list.iflook==1||$list.iflook==2}>
                <img align="absmiddle" src="image/default/user_admin/read.gif" width="16" height="14" />
            <{/if}>
            <a href="<{$config.weburl}>/main.php?m=message&s=admin_message_det&id=<{$list.id}>"><{$list.sub}></a>
        </td>
        <td>
            <{if $list.fromuserid or $list.msgtype=='3'}>
                <{if $list.msgtype=='3'}>
                    <{$lang.system_msg}>
                <{else}>
                    <{$list.fromname}>
                <{/if}>
            <{else}>
            	<{$lang.tourists}>
            <{/if}>
        </td>
        <td><{$list.date}></td>
    </tr>
    <{foreachelse}>
	<tr>
    	<td colspan="4" class="no"><{$lang.no_data}></td>
    </tr>
	<{/foreach}>
    <tr>
    	<td colspan="4" class="al">
            <input class="btn" name="del" type="submit" value="<{$lang.del}>" />
            <input class="btn" name="save" type="submit" value="<{$lang.transferred}>" />
			<div align="right"><{$re.page}></div>
        </td>
    </tr>
</table>
</form>