{include file="header.tpl"}
{literal}
<style  type="text/css">
div,li,ul,p,span,dl,dt,dd{ margin:0px; padding:0px; line-height:normal; font-size:12px;}
li{ list-style:none;}
h2{font-size:13px;}
.hidden{display:none;}
.clear{ display:block; clear:both; line-height:0px; height:0px;}
#upload_file_plugin{ margin:0px auto; padding:0px;}
#file_main_content{ margin:0px auto;}
.file_pic_list{height:150px; margin:5px; width:142px;overflow:hidden; float:left;}
.file_pic_list p{ height:20px; line-height:20px;text-align:center;}
.file_pic_list p a{}
.red{ color:#C00;}
.hoho{width:130px; height:120px; cursor:pointer; overflow:hidden; border:none;}
#upload_ok{ display: none; border:1px solid  #D2F0FF; margin:10px;padding:3px; line-height:180%; text-align: left; background-color:#F7FCFF;}
#file_man td{ padding:3px;}
</style>
{/literal}
<table width="100%">
<tr>
<td align="center" valign="top">
{literal}
<script type="text/javascript">
	function reload(obj){
		var v = $(obj).val();
		if(v!='0'){
			window.location.href='admincp.php?action=filemanager&type='+v;	
		}
	}
</script>
{/literal}
<div style=" padding:5px;">查看文件类型:<select onchange="reload(this)">
	<option value="0">请选择要查看的文件类型</option>
	<option value="default">图片类型文件</option>
    <option value="flv">flv视频</option>
    <option value="flash">flash文件</option>
    <option value="other">其他格式文件</option>
</select></div>
<br  class="clear"/>
<div style="padding-left:50px;">
{if $type eq 'default' || $type eq ''}
    {if $data.total>0}
{foreach from=$data.data item=list}
<div class="file_pic_list">
<a href="{$list.source_file}" target="_blank">
<img src="{$list.source_file}" title="文件名:{$list.file_name}|文件大小:{$list.file_size}" class="hoho file_img" name="{$list.file_name}"/>
</a>
<p align="center">
<a href="admincp.php?action=filemanager&task=delete&id={$list.fid}&type={$type}" name="{$list.fid}">删除</a>&nbsp; |  &nbsp;<a href="{$list.source_file}"  rel="jqcolorbox" target="_blank" >预览</a></p>
</div>
{/foreach}
  {if $data.page}
<br  class="clear"/>
<div id="file_page">{$data.page}</div>
{/if}

{else}
<div class="notice_msg">无可用数据</div>
{/if}
</div>
 {/if}
 
 {if $type eq 'flv' || $type eq 'flash' || $type eq 'other'}
 	{if $data.total>0}
<table width="100%" border="0" cellspacing="0" cellpadding="0" id="file_man">
  <tr>
  {foreach from=$data.data item=l}
    <td>文件名:{$l.file_name}&nbsp;&nbsp;文件大小:{$l.file_size}&nbsp;&nbsp;  <a href="admincp.php?action=filemanager&task=delete&id={$l.fid}&type={$type}" name="{$l.fid}">删除</a>&nbsp; |  &nbsp; <a href="{$l.source_file}" target="_blank">预览</a> </td>
  </tr>
  {/foreach}
</table>
    {else}
     	<div class="notice_msg">无可用数据</div>
    {/if}
 {/if}
 
</td>
</tr>
</table>
{include file="footer.tpl"}