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

502 lines
22KB

  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. <link rel="stylesheet" href="css/albumupload.css">
  11. <link rel="stylesheet" href="../static/web/css/daterangepicker.css">
  12. <link rel="stylesheet" href="../static/web/css/cropper.min.css">
  13. <link rel="stylesheet" href="../static/web/css/jquery.fileupload.css">
  14. <style>table{border-collapse:inherit}</style>
  15. <script>const cfg_uplitpic_cut = '<?php echo $cfg_uplitpic_cut; ?>';</script>
  16. <script src="../static/web/js/jquery.min.js"></script>
  17. <script src="../static/web/js/webajax.js"></script>
  18. <script src="../static/web/js/moment.min.js"></script>
  19. <script src="../static/web/js/daterangepicker.js"></script>
  20. <script src="../static/web/js/bootstrap.bundle.min.js"></script>
  21. <script src="js/main.js"></script>
  22. <script src="js/album.js"></script>
  23. <script src="js/handlers.js"></script>
  24. <script src="../static/web/js/cropper.min.js"></script>
  25. <script>
  26. var swfu = null;
  27. var vcc = 0;
  28. var albums = [];
  29. $(document).ready(function () {
  30. //添加图片
  31. $("#iptAlbumImages").change(function (event) {
  32. var files = event.target.files;
  33. for (var i = 0, f; f = files[i]; i++) {
  34. //如果不是图片忽略
  35. if (!f.type.match('image.*')) {
  36. continue;
  37. }
  38. //将图片渲染到浏览器
  39. var reader = new FileReader();
  40. reader.onload = (function (theFile) {
  41. return function (e) {
  42. litpicImgSrc = e.target.result;
  43. addImage(litpicImgSrc, 0);
  44. };
  45. })(f);
  46. reader.readAsDataURL(f);
  47. }
  48. $("#iptAlbumImages").val("");
  49. });
  50. });
  51. </script>
  52. </head>
  53. <body>
  54. <form name="form1" action="album_edit.php" enctype="multipart/form-data" method="post" onSubmit="return checkSubmitAlb();">
  55. <input type="hidden" name="channelid" value="<?php echo $channelid?>">
  56. <input type="hidden" name="id" value="<?php echo $aid?>">
  57. <input type="hidden" name="imagebody" value="">
  58. <input type="hidden" name="dopost" value="save">
  59. <input type="hidden" id="albums" name="albums" value="">
  60. <table width="98%" align="center" cellpadding="0" cellspacing="0" class="mt-3 mb-3">
  61. <tr>
  62. <td width="70%"><i class="fa fa-map"></i> <a href="catalog_do.php?cid=<?php echo $arcRow['typeid']?>&dopost=listArchives">图集列表</a> &gt; 修改图集</td>
  63. <td width="30%" align="right"><?php echo $backurl; ?><a class="btn btn-success btn-sm" href="catalog_main.php">栏目管理</a></td>
  64. </tr>
  65. </table>
  66. <table width="98%" align="center" cellpadding="0" cellspacing="0" id="head1">
  67. <tr>
  68. <td>
  69. <table cellpadding="0" cellspacing="0">
  70. <tr>
  71. <td width="80" height="28" align="center" bgcolor="#fbfce2">常规内容</td>
  72. </tr>
  73. </table>
  74. </td>
  75. </tr>
  76. </table>
  77. <table width="98%" align="center" cellpadding="2" cellspacing="2" id="needset" class="biz-border">
  78. <tr>
  79. <td class="bline">
  80. <table width="900" cellspacing="0" cellpadding="0">
  81. <tr>
  82. <td width="90"> 图集标题:</td>
  83. <td width="400"><input type="text" name="title" id="title" value="<?php echo $arcRow['title']; ?>" style="width:390px"></td>
  84. <td width="90"> 简略标题:</td>
  85. <td><input type="text" name="shorttitle" id="shorttitle" value="<?php echo $arcRow['shorttitle']; ?>" style="width:160px"></td>
  86. </tr>
  87. </table>
  88. </td>
  89. </tr>
  90. <tr>
  91. <td class="bline">
  92. <table width="900" cellspacing="0" cellpadding="0">
  93. <tr>
  94. <td width="90"> 自定义属性:</td>
  95. <td>
  96. <?php
  97. $dsql->SetQuery("SELECT * FROM `#@__arcatt` ORDER BY sortid ASC");
  98. $dsql->Execute();
  99. while($trow = $dsql->GetObject())
  100. {
  101. if($trow->att=='j') $jumpclick = " onclick='ShowUrlTr()'";
  102. else $jumpclick = '';
  103. if(preg_match("#".$trow->att."#", $arcRow['flag']))
  104. echo "<label class='mr-1'><input type='checkbox' name='flags[]' id='flags{$trow->att}' value='{$trow->att}' {$jumpclick} checked='checked'> {$trow->attname}[{$trow->att}]</label>";
  105. else
  106. echo "<label class='mr-1'><input type='checkbox' name='flags[]' id='flags{$trow->att}' value='{$trow->att}'{$jumpclick} /> {$trow->attname}[{$trow->att}]</label>";
  107. }
  108. ?></td>
  109. </tr>
  110. </table>
  111. </td>
  112. </tr>
  113. <tr>
  114. <td class="bline" id="redirecturltr" style="display:<?php echo (empty($addRow['redirecturl']) ? 'none' : 'block'); ?>">
  115. <table width="900" cellspacing="0" cellpadding="0">
  116. <tr>
  117. <td width="90"> 跳转网址:</td>
  118. <td><input type="text" name="redirecturl" id="redirecturl" value="<?php echo $addRow['redirecturl']?>" style="width:300px"></td>
  119. </tr>
  120. </table>
  121. </td>
  122. </tr>
  123. <tr>
  124. <td class="bline">
  125. <table width="900" cellspacing="0" cellpadding="0">
  126. <tr>
  127. <td width="90"> Tag标签:</td>
  128. <td><input type="text" name="tags" id="tags" value="<?php echo $tags; ?>" style="width:300px">(','号分开,单个标签小于12字节)</td>
  129. <td width="60">权重:</td>
  130. <td><input type="text" name="weight" id="weight" value="<?php echo $arcRow['weight']; ?>" style="width:60px">(越小越靠前)</td>
  131. </tr>
  132. </table>
  133. </td>
  134. </tr>
  135. <tr id="pictable">
  136. <td class="bline">
  137. <table width="900" cellspacing="0" cellpadding="0">
  138. <tr>
  139. <td width="90" height="80"> 缩略图:</td>
  140. <td>
  141. <input type="text" name="picname" id="picname" value="<?php echo $arcRow['litpic']?>" style="width:300px">
  142. <label><input type="checkbox" name="ddisremote" value="1" id="ddisremote"> 远程</label>
  143. <span class="btn btn-success btn-sm fileinput-button">上传图片<input type="file" name="files[]" id="iptAddImages"></span>
  144. <button type="button" name="Submit" onClick="SelectImage('form1.picname','');" class="btn btn-success btn-sm">选择图片</button>
  145. <button type="button" id="btnClearAll" class="btn btn-success btn-smete">清空</button>
  146. </td>
  147. <td align="center"><img src="<?php if($arcRow['litpic']!='') echo $arcRow['litpic']; else echo '../static/web/img/defaultpic.jpg'; ?>" id="litPic" class="thumbnail"></td>
  148. </tr>
  149. </table>
  150. </td>
  151. </tr>
  152. <tr>
  153. <td class="bline">
  154. <table width="900" cellspacing="0" cellpadding="0">
  155. <tr>
  156. <td width="90"> 来源:</td>
  157. <td width="260">
  158. <input type="text" name="source" id="source" value="<?php echo $arcRow['source']?>" style="width:160px">
  159. <button type="button" name="selsource" id="selsource" class="btn btn-success btn-sm">选择</button>
  160. </td>
  161. <td width="90">作者:</td>
  162. <td>
  163. <input type="text" name="writer" id="writer" value="<?php echo $arcRow['writer']?>" style="width:160px">
  164. <button type="button"name="selwriter" id="selwriter" class="btn btn-success btn-sm">选择</button>
  165. </td>
  166. </tr>
  167. </table>
  168. </td>
  169. </tr>
  170. <tr>
  171. <td class="bline">
  172. <table width="900" cellspacing="0" cellpadding="0">
  173. <tr>
  174. <td width="90"> 发布栏目:</td>
  175. <td width="360">
  176. <?php
  177. $typeOptions = GetOptionList($arcRow['typeid'],$cuserLogin->getUserChannel(),$channelid);
  178. echo "<select name='typeid' id='typeid' style='width:160px'>";
  179. if($arcRow['typeid']=='0') echo "<option value='0' selected>请选择主分类</option>";
  180. echo $typeOptions;
  181. echo '</select>';
  182. ?>
  183. <i class="btn btn-sm fa fa-search" style="cursor:pointer" onClick="ShowCatMap(event,this,<?php echo $channelid; ?>,'typeid','<?php echo $arcRow['typeid']; ?>')" title="快捷选择"></i>
  184. </td>
  185. <td width="90">消费金币:</td>
  186. <td><input type="text" name="money" id="money" value="<?php echo $arcRow['money']?>" style="width:160px"></td>
  187. </tr>
  188. </table>
  189. </td>
  190. </tr>
  191. <?php
  192. if($cfg_need_typeid2=='Y') {
  193. ?>
  194. <tr>
  195. <td class="bline">
  196. <table width="900" cellspacing="0" cellpadding="0">
  197. <tr>
  198. <td width="90"> 副栏目:</td>
  199. <td>
  200. <span id="typeid2ct"></span>
  201. <input type="text" name="typeid2" id="typeid2" value="<?php echo ($arcRow['typeid2']=='0' ? '' : $arcRow['typeid2']); ?>" style="width:160px">
  202. <i class="btn btn-sm fa fa-search" style="cursor:pointer" onClick="ShowCatMap(event,this,<?php echo $channelid; ?>,'typeid2','<?php echo $arcRow['typeid2']; ?>')" title="选择副栏目"></i>
  203. </td>
  204. </tr>
  205. </table>
  206. </td>
  207. </tr>
  208. <tr>
  209. <td class="bline">
  210. <table width="900" cellspacing="0" cellpadding="0">
  211. <tr>
  212. <td width="90"> 关键词:</td>
  213. <td><input type="text" name="keywords" id="keywords" value="<?php echo $arcRow['keywords']?>" style="width:360px"></td>
  214. </tr>
  215. </table>
  216. </td>
  217. </tr>
  218. <tr>
  219. <td class="bline">
  220. <table width="900" cellspacing="0" cellpadding="0">
  221. <tr>
  222. <td width="90"> 描述:</td>
  223. <td><textarea name="description" id="description" style="width:360px;height:50px"><?php echo $arcRow['description']?></textarea></td>
  224. </tr>
  225. </table>
  226. </td>
  227. </tr>
  228. <?php
  229. }
  230. ?>
  231. <tr>
  232. <td><?php PrintAutoFieldsEdit(stripslashes($cInfos['fieldset']),$addRow,'autofield');?></td>
  233. </tr>
  234. <tr>
  235. <td class="bline">
  236. <table width="900" cellspacing="0" cellpadding="0">
  237. <tr>
  238. <td width="90"> 表现方式:</td>
  239. <td>
  240. <label><input type="radio" name="pagestyle" id="pagestyle1" onClick="checkMuList()" value="1" <?php if($pagestyle==1) echo " checked='checked'"; ?>> <img src="../static/web/img/alb2.jpg" title="单页多图样式"></label>
  241. <label><input type="radio" name="pagestyle" id="pagestyle2" onClick="checkMuList()" value="2" <?php if($pagestyle==2) echo " checked='checked'"; ?>> <img src="../static/web/img/alb1.jpg" title="幻灯片样式"></label>
  242. <label><input type="radio" name="pagestyle" id="pagestyle3" onClick="checkMuList()" value="3" <?php if($pagestyle==3) echo " checked='checked'"; ?>> <img src="../static/web/img/alb3.jpg" title="多缩略图样式"></label>
  243. </td>
  244. </tr>
  245. </table>
  246. </td>
  247. </tr>
  248. <tr id="cfgmulist" style="<?php if($pagestyle!=3) echo 'display:none'; ?>">
  249. <td class="bline">
  250. <table width="900" cellspacing="0" cellpadding="0">
  251. <tr>
  252. <td width="90"> 多列式参数:</td>
  253. <td>
  254. 行 <input type="text" name="row" id="row" value="<?php echo $irow; ?>" size="6">
  255. 列 <input type="text" name="col" id="col" value="<?php echo $icol; ?>" size="6">
  256. 缩略图宽度限制:<input type="text" name="ddmaxwidth" id="ddmaxwidth" value="<?php echo $ddmaxwidth; ?>" size="6"> 像素
  257. </td>
  258. </tr>
  259. <tr>
  260. <td></td>
  261. <td>(系统仅是每页输出&quot;行x列&quot;张图片,实现需自行控制样式表)</td>
  262. </tr>
  263. </table>
  264. </td>
  265. </tr>
  266. <tr id="spagelist" style="<?php if($pagestyle!=1) echo 'display:none'; ?>">
  267. <td class="bline">
  268. <table width="900" cellspacing="0" cellpadding="0">
  269. <tr>
  270. <td width="90"> 每页图片数:</td>
  271. <td><input name="pagepicnum" id="pagpicnum" size="10" value="<?php echo $pagepicnum; ?>"> 单页多图显示需要设置此参数,这种模式下系统不会为每张图单独生成缩略图</td>
  272. </tr>
  273. </table>
  274. </td>
  275. </tr>
  276. <tr style="display:none">
  277. <td class="bline">
  278. <table width="900" cellspacing="0" cellpadding="0">
  279. <tr>
  280. <td width="90"> 限制宽度:</td>
  281. <td><input type="text" name="maxwidth" id="maxwidth" size="10" value="<?php echo $maxwidth?>">(防止图片太宽在模板页中溢出)</td>
  282. </tr>
  283. </table>
  284. </td>
  285. </tr>
  286. <tr>
  287. <td class="bline">
  288. <table width="900" cellspacing="0" cellpadding="0">
  289. <tr>
  290. <td width="90"> 上传方式:</td>
  291. <td>
  292. <input type="hidden" name="isrm" id="isrm" value="1">
  293. <label><input type="checkbox" name="byhand" id="byhand" value="1" disabled="ture" checked> 手工上传</label>
  294. <label><input type="checkbox" name="formzip" id="formzip" value="1" onClick="showZipField(this,'zipff','htmlfield')"> 从ZIP压缩包中解压图片</label>
  295. </td>
  296. </tr>
  297. </table>
  298. </td>
  299. </tr>
  300. <tr id="zipff" style="display:none">
  301. <td class="bline"><table width="900" cellspacing="0" cellpadding="0" height="100">
  302. <tr>
  303. <td width="90"> 压缩包文件:</td>
  304. <td>
  305. <input type="text" name="zipfile" id="zipfile" style="width:260px">
  306. <button type="button" name="addon_bt" class="btn btn-success btn-sm" onClick="SelectSoft('form1.zipfile')">浏览</button>
  307. <label><input type="checkbox" name="delzip" id="delzip" value="1" checked="checked"> 处理后删除压缩文件</label>
  308. </td>
  309. </tr>
  310. </table>
  311. </td>
  312. </tr>
  313. <tr id="htmlfield" style="display:none">
  314. <td class="bline"><table width="900" cellspacing="0" cellpadding="0">
  315. <tr>
  316. <td width="90"> 网上复制:</td>
  317. <td>
  318. 复制的源网址:<input type="text" name="copysource" value="http://" style="width:260px">(防盗链网站需填写您复制图片的其中一个网页网址)<br>
  319. 把图片从别的网页复制,在这里用Ctrl+V粘贴,提交后程序可直接获取这个区域的所有图片
  320. <input type="button" name="button" id="button" value="预览" onClick="LoadTestDiv()"><br>
  321. <div id="copyhtml" style="margin:10px 0;border:solid 1px #CCCCCC;width:96%;padding:6px;height:260px;width:100%" contenteditable="true">粘贴到这里</div>
  322. </td>
  323. </tr>
  324. </table>
  325. </td>
  326. </tr>
  327. <tr>
  328. <td class="bline">
  329. <table width="100%">
  330. <tr>
  331. <td>
  332. <div id="thumbnailsEdit">
  333. <?php
  334. $j = 1;
  335. if($imgurls!=""){
  336. $dtp = new DedeTagParse();
  337. $dtp->LoadSource($imgurls);
  338. if(is_array($dtp->CTags))
  339. {
  340. foreach($dtp->CTags as $ctag)
  341. {
  342. if($ctag->GetName()=="img")
  343. {
  344. $bigimg = trim($ctag->GetInnerText());
  345. if($ctag->GetAtt('ddimg') != $bigimg && $ctag->GetAtt('ddimg')!='')
  346. {
  347. $litimg = $ctag->GetAtt('ddimg');
  348. } else {
  349. $litimg = 'swfupload.php?dopost=ddimg&img='.$bigimg;
  350. }
  351. $fhtml = '';
  352. $fhtml .= "<div class='albCt albEdit' id='albold{$j}'>";
  353. $fhtml .= "<input type='hidden' name='imgurl{$j}' value='{$bigimg}'>";
  354. $fhtml .= "<input type='hidden' name='imgddurl{$j}' value='{$litimg}'>";
  355. $fhtml .= "<img src='{$litimg}'><a href=\"javascript:delAlbPicOld('$bigimg',$j)\" class=\"btn btn-success btn-sm\">删除</a>";
  356. $fhtml .= "<div class='mt-1'>名称:<input type='text' name='imgmsg{$j}' value='".$ctag->GetAtt('text')."' style='width:160px'></div>";
  357. $fhtml .= "<div class='mt-1'>更换:<input type='file' name='imgfile{$j}' style='width:160px'></div>";
  358. $fhtml .= "</div>";
  359. echo $fhtml;
  360. $j++;
  361. }
  362. }
  363. }
  364. $dtp->Clear();
  365. }
  366. ?>
  367. </div>
  368. </td>
  369. </tr>
  370. </table>
  371. </td>
  372. </tr>
  373. <tr>
  374. <td class="bline">
  375. <table width="900" cellspacing="0" cellpadding="0">
  376. <tr>
  377. <td width="90"> 增加新图片:</td>
  378. <td><span class="btn btn-success btn-sm fileinput-button"><i class="glyphicon glyphicon-plus"></i> 选择本地图片(支持多选)<input type="file" name="files[]" id="iptAlbumImages" multiple></span></td>
  379. </tr>
  380. </table>
  381. </td>
  382. </tr>
  383. <tr>
  384. <td class="bline">
  385. <table width="100%">
  386. <tr>
  387. <td>
  388. <div id="divFileProgressContainer"></div>
  389. <div id="thumbnails"></div>
  390. </td>
  391. </tr>
  392. </table>
  393. </td>
  394. </tr>
  395. <tr>
  396. <td class="bline">
  397. <table width="900" cellspacing="0" cellpadding="0">
  398. <tr>
  399. <td width="90"> 图集内容:</td>
  400. <td><?php GetEditor("body",$body,450,"Diy");?></td>
  401. </tr>
  402. </table>
  403. </td>
  404. </tr>
  405. <tr>
  406. <td class="bline">
  407. <table width="900" cellspacing="0" cellpadding="0">
  408. <tr>
  409. <td width="90" width="260"> 评论选项:</td>
  410. <td width="260">
  411. <label><input type="radio" name="notpost" value="0" <?php if($arcRow['notpost']==0) echo "checked='1'"; ?>> 允许评论</label>
  412. <label><input type="radio" name="notpost" value="1" <?php if($arcRow['notpost']==1) echo "checked='1'"; ?>> 禁止评论</label>
  413. </td>
  414. <td width="90">发布选项:</td>
  415. <td>
  416. <label><input type="radio" name="ishtml" value="1" <?php if($arcRow["ismake"]!=-1) echo "checked"; ?>> 生成网页</label>
  417. <label><input type="radio" name="ishtml" value="0" <?php if($arcRow["ismake"]==-1) echo "checked"; ?>> 仅动态浏览</label>
  418. </td>
  419. </tr>
  420. </table>
  421. </tr>
  422. <tr>
  423. <td class="bline">
  424. <table width="900" cellspacing="0" cellpadding="0">
  425. <tr>
  426. <td width="90"> 文档排序:</td>
  427. <td width="260">
  428. <select name="sortup" id="sortup" style="width:160px">
  429. <?php
  430. $subday = SubDay($arcRow["sortrank"],$arcRow["pubdate"]);
  431. echo "<option value='0'>正常排序</option>";
  432. if($subday>0) echo "<option value='$subday' selected>置顶 $subday 天</option>";
  433. ?>
  434. <option value="7">置顶一周</option>
  435. <option value="30">置顶一个月</option>
  436. <option value="90">置顶三个月</option>
  437. <option value="180">置顶半年</option>
  438. <option value="360">置顶一年</option>
  439. </select></td>
  440. <td width="90">标题颜色:</td>
  441. <td>
  442. <input type="text" name="color" id="color" value="<?php echo $arcRow['color']?>" style="width:160px">
  443. <button type="button" name="modcolor" id="modcolor" class="btn btn-success btn-sm" onClick="ShowColor(event,this)">选取</button>
  444. </td>
  445. </tr>
  446. </table>
  447. </td>
  448. </tr>
  449. <tr>
  450. <td class="bline">
  451. <table width="900" cellspacing="0" cellpadding="0">
  452. <tr>
  453. <td width="90"> 阅读权限:</td>
  454. <td width="260">
  455. <select name="arcrank" id="arcrank" style="width:160px">
  456. <option value="<?php echo $arcRow['arcrank']?>"> <?php echo $arcRow["rankname"]?> </option>
  457. <?php
  458. $urank = $cuserLogin->getUserRank();
  459. $dsql->SetQuery("Select * from #@__arcrank where adminrank<='$urank'");
  460. $dsql->Execute();
  461. while($row = $dsql->GetObject()){
  462. echo "<option value='".$row->rank."'>".$row->membername."</option>";
  463. }
  464. ?>
  465. </select>
  466. </td>
  467. <td width="90">文件名称:</td>
  468. <td><input type="text" name="filename" id="filename" value="<?php echo $arcRow['filename']?>" style="width:160px">(不包括后缀名如.html等)</td>
  469. </tr>
  470. </table>
  471. </td>
  472. </tr>
  473. <tr>
  474. <td class="bline">
  475. <table width="900" cellspacing="0" cellpadding="0">
  476. <tr>
  477. <td width="90"> 发布时间:</td>
  478. <td width="260">
  479. <?php
  480. $nowtime = GetDateTimeMk(time());
  481. echo "<input type='text' name='pubdate' value='$nowtime' id='pubdate' class='datepicker' style='width:160px'>";
  482. ?>
  483. </td>
  484. <td width="90">浏览次数:</td>
  485. <td><input type="text" name="click" value="<?php echo $arcRow['click']; ?>" style="width:160px"></td>
  486. </tr>
  487. </table>
  488. </td>
  489. </tr>
  490. </table>
  491. <table width="98%" cellspacing="0" cellpadding="0" align="center" bgcolor="#f8f8f8" class="biz-border border-top-0 mb-3">
  492. <tr>
  493. <td align="center" class="py-2">
  494. <button type="submit" class="btn btn-success btn-sm">保存</button>
  495. <button type="button" onClick="location.reload();" class="btn btn-success btn-sm">重置</button>
  496. </td>
  497. </tr>
  498. </table>
  499. </form>
  500. <script>InitPage();</script>
  501. </body>
  502. </html>