国内流行的内容管理系统(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.

123 lines
4.9KB

  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/css/bootstrap.min.css">
  8. <link rel="stylesheet" href="../static/web/font/css/font-awesome.min.css">
  9. <link rel="stylesheet" href="../static/web/css/admin.css">
  10. <script src="../static/web/js/jquery.min.js"></script>
  11. <script src="../static/web/js/bootstrap.bundle.min.js"></script>
  12. <script src="js/main.js"></script>
  13. <style>
  14. .coolbg2 {
  15. border: 1px solid #000000;
  16. background: #F2F5E9;
  17. height: 18px
  18. }
  19. </style>
  20. <script>
  21. function CheckSubmit() {
  22. if (document.form1.title.value == "") {
  23. ShowMsg("请设置标题");
  24. document.form1.title.focus();
  25. return false;
  26. }
  27. }
  28. </script>
  29. </head>
  30. <body>
  31. <table width="98%" align="center" cellpadding="3" cellspacing="1" class="table maintable mt-3 mb-3">
  32. <tr>
  33. <td bgcolor="#f8f8f8">
  34. <table width="98%" cellpadding="0" cellspacing="0" class="table table-borderless">
  35. <tr>
  36. <td width="30%">修改媒体</td>
  37. <td width="70%" align="right"><a href="media_main.php" class="btn btn-success btn-sm">附件媒体数据管理</a></td>
  38. </tr>
  39. </table>
  40. </td>
  41. </tr>
  42. <tr>
  43. <td>
  44. <div class="alert alert-info mb-0">图片类型仅支持jpg、png、gif、wbmp格式,flash为.swf格式,视音频和附件为限定扩展名的类型(可在系统参数中修改)</div>
  45. </td>
  46. </tr>
  47. <tr>
  48. <td align="center">
  49. <table width="100%" cellpadding="0" cellspacing="0">
  50. <form enctype="multipart/form-data" name="form1" action="media_edit.php" method="POST" onSubmit="return CheckSubmit();">
  51. <input type="hidden" name="dopost" value="save">
  52. <input type="hidden" name="_csrf_token" value="<?php echo $GLOBALS['csrf_token'];?>">
  53. <input type="hidden" name="aid" value="<?php echo $aid?>">
  54. <tr>
  55. <td width="15%" align="left" class="bline">媒体类型:</td>
  56. <td width="85%" align="left" class="bline">
  57. <label><input type="radio" name="mediatype" value="1" <?php if($myrow['mediatype']==1) echo "checked";?>> 图片</label>
  58. <label><input type="radio" name="mediatype" value="2" <?php if($myrow['mediatype']==2) echo "checked";?>> FLASH</label>
  59. <label><input type="radio" name="mediatype" value="3" <?php if($myrow['mediatype']==3) echo "checked";?>> 视频音频</label>
  60. <label><input type="radio" name="mediatype" value="4" <?php if($myrow['mediatype']==4) echo "checked";?>> 附件其它</label>
  61. </td>
  62. </tr>
  63. <tr>
  64. <td class="bline">说明标题:</td>
  65. <td class="bline"><input type="text" name="title" id="title" value="<?php echo $myrow['title']?>" style="width:300px"></td>
  66. </tr>
  67. <tr>
  68. <td class="bline">参数说明:</td>
  69. <td class="bline" colspan="2">图片不需要指定“宽”、“高”,其它附加参数仅方便多媒体文件管理,没其它含义</td>
  70. </tr>
  71. <tr>
  72. <td class="bline">附加参数:</td>
  73. <td class="bline">
  74. 宽:<input type="text" name="mediawidth" id="mediawidth" value="<?php echo $myrow['width']?>" style="width:60px">(像素)
  75. 高:<input type="text" name="mediaheight" id="mediaheight" value="<?php echo $myrow['height']?>" style="width:60px">(像素)
  76. 播放时间:<input type="text" name="playtime" id="playtime" value="<?php echo $myrow['playtime']?>" style="width:60px">(分钟)
  77. </td>
  78. </tr>
  79. <tr>
  80. <td class="bline">原文件:</td>
  81. <td class="bline">
  82. <input type="text" name="filename" id="filename" value="<?php echo $myrow['url']?>" style="width:260px">
  83. <a href="<?php echo $myrow['url']?>" target="_blank">[查看]</a>
  84. </td>
  85. </tr>
  86. <?php
  87. if($myrow['mediatype']==1)
  88. {
  89. $fullfilename = $cfg_basedir.$myrow['url'];
  90. if(file_exists($fullfilename)){
  91. $info = "";
  92. $sizes = getimagesize($fullfilename,$info);
  93. if(is_array($sizes)){
  94. if($sizes[0]>200) $w=200;
  95. else $w = $sizes[0];
  96. ?>
  97. <tr>
  98. <td class="bline">预览:</td>
  99. <td class="bline"><a href="<?php echo $myrow['url']?>" target="_blank"><img src="<?php echo $myrow['url'].'?q='.time()?>" width="<?php echo $w?>" id="picview"></a></td>
  100. </tr>
  101. <?php } } } ?>
  102. <tr>
  103. <td class="bline">修改文件:</td>
  104. <td class="bline">
  105. <input name="upfile" type="file" id="upfile" style="width:260px">
  106. </td>
  107. </tr>
  108. <tr>
  109. <td colspan="2" class="bline">
  110. <table width="100%" cellspacing="0" cellpadding="0" class="table table-borderless">
  111. <tr>
  112. <td align="center" class="py-2"><button type="submit" class="btn btn-success btn-sm">保存</button></td>
  113. </tr>
  114. </table>
  115. </td>
  116. </tr>
  117. </form>
  118. </table>
  119. </td>
  120. </tr>
  121. </table>
  122. </body>
  123. </html>