国内流行的内容管理系统(CMS)多端全媒体解决方案 https://www.dedebiz.com
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

117 lines
5.0KB

  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="<?php echo $cfg_soft_lang;?>">
  5. <meta http-equiv="X-UA-Compatible" content="IE=Edge,chrome=1">
  6. <title>附件数据管理</title>
  7. <link rel="stylesheet" href="../static/web/font/css/font-awesome.min.css">
  8. <link rel="stylesheet" href="../static/web/css/bootstrap.min.css">
  9. <link rel="stylesheet" href="../static/web/css/admin.css">
  10. <style>.napisdiv{position:absolute;left:10;top:0;width:150px;height:100px;z-index:3}</style>
  11. <script>
  12. //获得选中文件的文件名
  13. function getCheckboxItem() {
  14. var allSel = "";
  15. if (document.form1.aids.value) return document.form1.aids.value;
  16. for (i = 0; i < document.form1.aids.length; i++) {
  17. if (document.form1.aids[i].checked) {
  18. if (allSel == "")
  19. allSel = document.form1.aids[i].value;
  20. else
  21. allSel = allSel + "," + document.form1.aids[i].value;
  22. }
  23. }
  24. return allSel;
  25. }
  26. function AllSel() {
  27. for (i = 0; i < document.form1.aids.length; i++) {
  28. document.form1.aids[i].checked = true;
  29. }
  30. }
  31. function NoneSel() {
  32. for (i = 0; i < document.form1.aids.length; i++) {
  33. document.form1.aids[i].checked = false;
  34. }
  35. }
  36. function DelSel() {
  37. var nid = getCheckboxItem();
  38. if (nid == "") {
  39. alert("请选择项目");
  40. return;
  41. }
  42. location.href = "media_edit.php?dopost=del&ids=" + nid;
  43. }
  44. </script>
  45. </head>
  46. <body>
  47. <table width="98%" cellpadding="3" cellspacing="1" align="center" class="table maintable my-3">
  48. <form name="forms" method="post" action="media_main.php">
  49. <tr bgcolor="#f5f5f5">
  50. <td width="280" align="center">
  51. <input type="text" name="keyword" id="keyword" placeholder="请输入关键词" value="<?php echo $keyword?>" class="biz-input-md">
  52. </td>
  53. <td width="170">
  54. <select name="mediatype" class="biz-input-sm">
  55. <option value="0">文件类型</option>
  56. <option value="1" <?php if ($mediatype==1) echo "selected"?>>图片</option>
  57. <option value="2" <?php if ($mediatype==2) echo "selected"?>>FLASH</option>
  58. <option value="3" <?php if ($mediatype==3) echo "selected"?>>视频音频</option>
  59. <option value="4" <?php if ($mediatype==4) echo "selected"?>>其它附件</option>
  60. </select>
  61. </td>
  62. <td width="170">
  63. <select name="membertype" class="biz-input-sm">
  64. <option value="0">用户组</option>
  65. <option value="1" <?php if ($membertype==1) echo "selected"?>>管理员</option>
  66. <option value="2" <?php if ($membertype==2) echo "selected"?>>外部会员</option>
  67. </select>
  68. </td>
  69. <td>
  70. <button type="submit" class="btn btn-success btn-sm">搜索</button>
  71. <a href="media_add.php" class="btn btn-success btn-sm">上传新文件</a>
  72. </td>
  73. </tr>
  74. </form>
  75. </table>
  76. <table width="98%" cellpadding="3" cellspacing="1" align="center" class="table maintable mb-3">
  77. <tr>
  78. <td bgcolor="#f5f5f5" colspan="7">附件数据管理</td>
  79. </tr>
  80. <tr bgcolor="#fbfce2" align="center">
  81. <td width="6%">选择</td>
  82. <td width="28%">文件标题</td>
  83. <td width="10%">文件大小</td>
  84. <td width="15%">上传会员</td>
  85. <td width="15%">上传时间</td>
  86. <td width="10%">文件类型</td>
  87. <td>管理</td>
  88. </tr>
  89. <form name="form1">
  90. {dede:datalist empty='<tr><td colspan="7"><center>暂无内容</center></td></tr>'}
  91. <tr align="center" onmousemove="javascript:this.bgColor='#fbfce2';" onmouseout="javascript:this.bgColor='#ffffff';">
  92. <td><input type="checkbox" name="aids" id="aids{dede:field.aid/}" value="{dede:field.aid/}"></td>
  93. <td><a href="{dede:field.url/}" title="{dede:field.url/}" target="_blank">{dede:field.title/}</a></td>
  94. <td>{dede:field.filesize function='GetFileSize(@me)'/}</td>
  95. <td>{dede:field.adminname function="UploadAdmin(@me,$fields['membername'])"/}</td>
  96. <td>{dede:field.uptime function="MyDate('Y-m-d H:i',@me)"/}</td>
  97. <td>{dede:field.mediatype function="MediaType(@me,$fields['url'])"/}</td>
  98. <td>
  99. <a href="media_edit.php?aid={dede:field.aid/}&dopost=edit" class="btn btn-success btn-sm"><i class="fa fa-pencil-square-o"></i> 修改</a>
  100. <a href="media_edit.php?aid={dede:field.aid/}&dopost=del" class="btn btn-danger btn-sm"><i class="fa fa-trash"></i> 删除</a>
  101. </td>
  102. </tr>
  103. {/dede:datalist}
  104. <tr>
  105. <td colspan="7">
  106. <button type="button" name="b4" onClick="AllSel();" class="btn btn-success btn-sm">全选</button>
  107. <button type="button" name="b5" onClick="NoneSel();" class="btn btn-success btn-sm">取消</button>
  108. <button type="button" name="b6" onClick="DelSel();" class="btn btn-danger btn-sm">删除</button>
  109. </td>
  110. </tr>
  111. <tr bgcolor="#f5f5f5" class="py-2">
  112. <td colspan="7" align="center">{dede:pagelist listsize='6'/}</td>
  113. </tr>
  114. </form>
  115. </table>
  116. </body>
  117. </html>