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

316 lines
16KB

  1. <!DOCTYPE html
  2. PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  3. <html xmlns="http://www.w3.org/1999/xhtml">
  4. <head>
  5. <meta http-equiv="Content-Type" content="text/html; charset=<?php echo $cfg_soft_lang; ?>">
  6. <title>栏目管理--快速创建栏目</title>
  7. <script type="text/javascript" src="../static/js/jquery.js"></script>
  8. <script type="text/javascript">
  9. var $ = jQuery;
  10. $(document).ready(function () {
  11. //删除按钮事件
  12. $("#addQuick .del").click(function () {
  13. $(this).parents(".repeat").remove();
  14. });
  15. //添加按钮事件
  16. $("#add").click(function () {
  17. var id = $("#addQuick tr").prevAll("tr").length + 1;
  18. $("#addQuick tr:eq(1)").clone(true).addClass("repeat")
  19. .find(".rank input")
  20. .attr("value", function () { return id })
  21. .end()
  22. .find(".pubinputs")
  23. .attr("name", function () { return this.name + id })
  24. .attr("id", function () { return this.id + id })
  25. .end()
  26. .appendTo($("#addQuick"));
  27. });
  28. //删除按钮事件
  29. $("#addQuickRel .del").click(function () {
  30. $(this).parents(".repeat").remove();
  31. });
  32. //添加按钮事件
  33. $("#addrel").click(function () {
  34. var id = $("#addQuickRel tr").prevAll("tr").length + 1;
  35. $("#addQuickRel tr:eq(1)").clone(true).addClass("repeat")
  36. .find(".rank input")
  37. .attr("value", function () { return id })
  38. .end()
  39. .find(".pubinputs")
  40. .attr("name", function () { return this.name + id })
  41. .attr("id", function () { return this.id + id })
  42. .end()
  43. .appendTo($("#addQuickRel"));
  44. });
  45. });
  46. </script>
  47. <script language="javascript">
  48. function ShowHide(objname) {
  49. var obj = document.getElementById(objname);
  50. if (obj.style.display == "block" || obj.style.display == "")
  51. obj.style.display = "none";
  52. else
  53. obj.style.display = "block";
  54. }
  55. function ShowObj(objname) {
  56. var obj = document.getElementById(objname);
  57. obj.style.display = "block";
  58. }
  59. function HideObj(objname) {
  60. var obj = document.getElementById(objname);
  61. obj.style.display = "none";
  62. }
  63. function showSeltype(objname) {
  64. if (objname.value != 0) {
  65. $("#addQuickRel").show();
  66. $("#pathtype").show();
  67. $("#addQuick").hide();
  68. $("#savetype").val('rel');
  69. } else {
  70. $("#addQuickRel").hide();
  71. $("#addQuick").show();
  72. $("#pathtype").hide();
  73. $("#savetype").val('');
  74. }
  75. }
  76. </script>
  77. <link rel="stylesheet" href="../static/css/bootstrap.min.css">
  78. <link href="../static/font-awesome/css/font-awesome.min.css" rel="stylesheet">
  79. <link href='css/base.css' rel='stylesheet' type='text/css'>
  80. <style>
  81. .table {
  82. margin: 0;
  83. }
  84. </style>
  85. </head>
  86. <body leftmargin='15' topmargin='10'>
  87. <form name="form1" action="catalog_add.php" method="post">
  88. <input type="hidden" name="dopost" value="savequick" />
  89. <input type="hidden" name="savetype" value="" id="savetype" />
  90. <table width="98%" border="0" align="center" cellpadding="0" cellspacing="0" bordercolor="#111111"
  91. style="BORDER-COLLAPSE: collapse" class="mt-3">
  92. <tr>
  93. <td width="100%" height="20" valign="top">
  94. <table width="100%" border="0" cellspacing="0" cellpadding="0">
  95. <tr>
  96. <td height="30"><img height='14' src='images/book1.gif' width='20' />&nbsp;<a
  97. href="catalog_main.php">栏目管理</a> &gt;&gt; 批量增加栏目 </td>
  98. </tr>
  99. </table>
  100. </td>
  101. </tr>
  102. <tr>
  103. <td width="100%" height="1" background="images/sp_bg.gif"></td>
  104. </tr>
  105. </table>
  106. <table width="98%" border="0" align="center" cellpadding="0" cellspacing="0">
  107. <tr>
  108. <td height="10"></td>
  109. </tr>
  110. <tr>
  111. <td height="95" align="left" bgcolor="#FFFFFF">
  112. <table width="100%" border="0" cellspacing="0" id="head1" cellpadding="0">
  113. <tr>
  114. <td colspan="2" bgcolor="#FFFFFF">
  115. <table width="84" border="0" cellpadding="0" cellspacing="0">
  116. <tr>
  117. <td width="84" height="24" align="center" background="images/itemnote1.gif">&nbsp;常规选项&nbsp;</td>
  118. </tr>
  119. </table>
  120. </td>
  121. </tr>
  122. </table>
  123. <table width="100%" border="0" id="needset" cellspacing="0" cellpadding="0"
  124. style="border:1px solid #cfcfcf;background:#ffffff;text-align:left;" class="table">
  125. <tr>
  126. <td height="24" bgcolor="#F9FCEF" style="padding-left:10px;"><strong>公用参数:</strong></td>
  127. <td bgcolor="#F9FCEF"></td>
  128. </tr>
  129. <tr>
  130. <td width="150" class='bline' height="26" style="padding-left:10px;">是否支持投稿:</td>
  131. <td class='bline'>
  132. <label><input type='radio' name='issend' value='0' class='np' />
  133. 不支持</label>
  134. &nbsp;
  135. <label><input type='radio' name='issend' value='1' class='np' checked='1' />
  136. 支持</label> </td>
  137. </tr>
  138. <tr>
  139. <td class='bline' height="26" style="padding-left:10px;">目录保存位置:</td>
  140. <td class='bline'>
  141. <input name="referpath" type="radio" id="truepath1" class="np" value="parent"
  142. checked='1' />
  143. <label for="truepath1">默认HMTL目录(
  144. <?php
  145. $pardir = '{cmspath}'.$cfg_arcdir;
  146. if(!empty($typedir)) $pardir = $typedir.'/';
  147. $pardir = preg_replace("#\/{1,}#", '/', $pardir);
  148. echo $pardir;
  149. ?>
  150. )</label>
  151. <input name="referpath" type="radio" id="truepath2" class="np" value="cmspath" />
  152. <label for="truepath2">CMS根目录</label>
  153. <input name="nextdir" type="hidden" id="nextdir" value="<?php echo $pardir; ?>" />
  154. <span id="pathtype" style="display:none"><input name="referpath" type="radio" id="truepath3" class="np"
  155. value="typepath" />
  156. 隶属栏目所属的目录</span></td>
  157. </tr>
  158. <tr>
  159. <td class='bline' height="26" style="padding-left:10px;">隶属栏目:</td>
  160. <td class='bline'>
  161. <select name='reid' onchange="showSeltype(this)">
  162. <option value='0'>选择所属目录... </option>
  163. <?php echo $typeOptions;?>
  164. </select>
  165. (默认为顶级栏目)
  166. </td>
  167. </tr>
  168. <tr>
  169. <td class='bline' height="26" style="padding-left:10px;">内容模型: &nbsp; </td>
  170. <td class='bline'><select name="channeltype" id="channeltype" style="width:200px"
  171. onChange="ParTemplet(this)">
  172. <?php
  173. foreach($channelArray as $k=>$arr)
  174. {
  175. if($k==$channelid) echo " <option value='{$k}' selected>{$arr['typename']}|{$arr['nid']}</option>\r\n";
  176. else echo " <option value='{$k}'>{$arr['typename']}|{$arr['nid']}</option>\r\n";
  177. }
  178. ?>
  179. </select>
  180. </td>
  181. </tr>
  182. <tr>
  183. <td class='bline' height="26" style="padding-left:10px;">栏目列表选项:</td>
  184. <td class='bline'>
  185. <label><input type='radio' name='isdefault' value='1' class='np' checked='1' />
  186. 链接到默认页</label>
  187. <label><input type='radio' name='isdefault' value='0' class='np' />
  188. 链接到列表第一页</label>
  189. <label><input type='radio' name='isdefault' value='-1' class='np' />
  190. 使用动态页</label> </td>
  191. </tr>
  192. <tr>
  193. <td class='bline' height="26" style="padding-left:10px;">默认页的名称: </td>
  194. <td class='bline'><input name="defaultname" type="text" value="index.html" class="pubinputs" /></td>
  195. </tr>
  196. <tr id='helpvar2' style='display:none'>
  197. <td height="24" bgcolor="#F3F7EA" style="padding-left:10px;">支持变量: </td>
  198. <td height="24" bgcolor="#F3F7EA"> {Y}、{M}、{D} 年月日<br />
  199. {timestamp} INT类型的UNIX时间戳<br />
  200. {aid} 文章ID<br />
  201. {pinyin} 拼音+文章ID<br />
  202. {py} 拼音部首+文章ID<br />
  203. {typedir} 栏目目录 <br />
  204. {cc} 日期+ID混编后用转换为适合的字母 <br />
  205. </td>
  206. </tr>
  207. <tr>
  208. <td height="26" class='bline' style="padding-left:10px;">文章命名规则:</td>
  209. <td class='bline'><input name="namerule" type="text" id="namerule" value="{typedir}/{Y}{M}{D}/{aid}.html"
  210. size="40" class="pubinputs" />
  211. <img src="images/help.gif" alt="帮助" width="16" height="16" border="0" style="cursor:pointer"
  212. onClick="ShowHide('helpvar2')" /> </td>
  213. </tr>
  214. <tr id='helpvar3' style='display:none'>
  215. <td height="24" bgcolor="#F3F7EA" style="padding-left:10px;">支持变量: </td>
  216. <td bgcolor="#F3F7EA">{page} 列表的页码</td>
  217. </tr>
  218. <tr>
  219. <td height="26" style="padding-left:10px;">列表命名规则:</td>
  220. <td><input name="namerule2" type="text" id="namerule2" value="{typedir}/list_{tid}_{page}.html" size="40"
  221. class="pubinputs" />
  222. <img src="images/help.gif" alt="帮助" width="16" height="16" border="0" style="cursor:pointer"
  223. onClick="ShowHide('helpvar3')" /></td>
  224. </tr>
  225. <tr>
  226. <td height="24" bgcolor="#F9FCEF" style="padding-left:10px;"><strong>栏目填写:</strong></td>
  227. <td bgcolor="#F9FCEF"></td>
  228. </tr>
  229. <tr>
  230. <td colspan='2' style="padding:5px 0px 8px 10px">
  231. <table id="addQuick" width="850" border="0" cellpadding="3" cellspacing="1" bgcolor="#cfcfcf">
  232. <tbody>
  233. <tr bgcolor="#FBFCE2" align="center">
  234. <td width="60" height="28">排序</td>
  235. <td width="170">顶级栏目名称</td>
  236. <td width="520">子栏目(用&quot;目录名称1,目录名称2...&quot;这样表示多个栏目)</td>
  237. <td width="250" align="center"><button type="button" id="add" class="btn btn-success btn-sm">添加</button>
  238. </td>
  239. </tr>
  240. <tr bgcolor="#FFFFFF" height="32" align="center">
  241. <td class="rank" style="padding:5px;"><input type="hidden" name="posttype" value=""
  242. class="pubinputs" />
  243. <input type="text" name="rank" id="rank" value="1" class="pubinputs" style="width:50px;" /></td>
  244. <td align='center'><input type="text" name="toptype" id="toptype" class="pubinputs"
  245. style="width:160px;" /></td>
  246. <td><input type="text" name="sontype" id="sontype" class="pubinputs" style="width:480px;" /></td>
  247. <td align="center"><button name="" type="button" id="add" class="btn btn-success btn-sm del">删除</button></td>
  248. </tr>
  249. <?php for($i=2;$i<=10;$i++) { ?>
  250. <tr bgcolor="#FFFFFF" height="32" class="repeat" align="center">
  251. <td class="rank"><input type="hidden" name="posttype<?php echo $i; ?>"
  252. value="<?php echo $i; ?>" />
  253. <input type="text" name="rank<?php echo $i; ?>" id="rank<?php echo $i; ?>"
  254. value="<?php echo $i; ?>" class="pubinputs" style="width:50px;" /></td>
  255. <td align='center'><input type="text" name="toptype<?php echo $i; ?>"
  256. id="toptype<?php echo $i; ?>" class="pubinputs" style="width:160px;" /></td>
  257. <td><input type="text" name="sontype<?php echo $i; ?>" id="sontype<?php echo $i; ?>"
  258. class="pubinputs" style="width:480px;" /></td>
  259. <td align="center"><button name="" type="button" id="add" class="btn btn-success btn-sm del">删除</button></td>
  260. </tr>
  261. <?php } ?>
  262. </tbody>
  263. </table>
  264. <table id="addQuickRel" width="302" border="0" cellpadding="3" cellspacing="1" bgcolor="#cfcfcf"
  265. style="display:none">
  266. <tbody>
  267. <tr bgcolor="#FBFCE2" align="center">
  268. <td width="60" height="28">排序</td>
  269. <td width="170">栏目名称</td>
  270. <td width="250" align="center"><button type="button" id="addrel" class="btn btn-success btn-sm">添加</button>
  271. </td>
  272. </tr>
  273. <tr bgcolor="#FFFFFF" height="32" align="center">
  274. <td class="rank" style="padding:5px;"><input type="hidden" name="posttype" value=""
  275. class="pubinputs" />
  276. <input type="text" name="rank" id="rank" value="1" class="pubinputs" style="width:50px;" /></td>
  277. <td align='center'><input type="text" name="reltype" id="reltype" class="pubinputs"
  278. style="width:160px;" /></td>
  279. <td align="center"><button name="" type="button" id="add" class="btn btn-success btn-sm del">删除</button></td>
  280. </tr>
  281. <?php for($i=2;$i<=10;$i++) { ?>
  282. <tr bgcolor="#FFFFFF" height="32" class="repeat" align="center">
  283. <td class="rank"><input type="hidden" name="posttype<?php echo $i; ?>"
  284. value="<?php echo $i; ?>" />
  285. <input type="text" name="rank<?php echo $i; ?>" id="rank<?php echo $i; ?>"
  286. value="<?php echo $i; ?>" class="pubinputs" style="width:50px;" /></td>
  287. <td align='center'><input type="text" name="reltype<?php echo $i; ?>"
  288. id="reltype<?php echo $i; ?>" class="pubinputs" style="width:160px;" /></td>
  289. <td align="center"><button type="button" id="add" class="btn btn-success btn-sm del">删除</button></td>
  290. </tr>
  291. <?php } ?>
  292. </tbody>
  293. </table>
  294. </td>
  295. </tr>
  296. </table>
  297. <table width="100%" border="0" cellspacing="0" cellpadding="0" bgcolor="#F9FCEF"
  298. style="border:1px solid #cfcfcf;border-top:none;" class="mb-3">
  299. <tr>
  300. <td width="1%" height="36"></td>
  301. <td width="99%" valign="bottom" class="py-3"><button type="submit" class="btn btn-success">确定</button>
  302. &nbsp;&nbsp;&nbsp; <a href="catalog_main.php" class="btn btn-success">返回</a></td>
  303. </tr>
  304. </table>
  305. </td>
  306. </tr>
  307. </table>
  308. </form>
  309. </body>
  310. </html>