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

177 lines
8.1KB

  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  2. <html xmlns="http://www.w3.org/1999/xhtml">
  3. <head>
  4. <meta http-equiv="Content-Type" content="text/html; charset=<?php echo $cfg_soft_lang; ?>">
  5. <title>主页更新向导</title>
  6. <script src="../static/js/jquery.js" language="javascript" type="text/javascript"></script>
  7. <link rel="stylesheet" href="../static/css/bootstrap.min.css">
  8. <link href="../static/font-awesome/css/font-awesome.min.css" rel="stylesheet">
  9. <link href="css/base.css" rel="stylesheet" type="text/css">
  10. <script language="javascript">
  11. function SelectTemplets(fname) {
  12. var posLeft = 200;
  13. var posTop = 300;
  14. window.open("./dialog/select_templets.php?f=" + fname, "poptempWin", "scrollbars=yes,resizable=yes,statebar=no,width=600,height=400,left=" + posLeft + ", top=" + posTop);
  15. }
  16. function htmlSubmit() {
  17. form1.submit();
  18. $("#dedebiz_admin").val("");
  19. }
  20. </script>
  21. </head>
  22. <body background="images/allbg.gif" leftmargin="8" topmargin="8">
  23. <table width="98%" border="0" cellpadding="3" cellspacing="1" bgcolor="#D6D6D6" align="center"
  24. class="table maintable table-bordered mt-3">
  25. <form name="form1" action="makehtml_homepage.php" target="stafrm" method="post">
  26. <input type="hidden" name="dopost" value="make">
  27. <tr>
  28. <td height="28" colspan="2" background='images/tbg.gif'>
  29. <table width="98%" border="0" cellpadding="0" cellspacing="0" class="table table-borderless">
  30. <tr>
  31. <td width="30%" height="18" style="padding-left:10px;"><strong>主页更新向导:</strong></td>
  32. <td width="70%" align="right">&nbsp;</td>
  33. </tr>
  34. </table>
  35. </td>
  36. </tr>
  37. <tr>
  38. <td width="177" valign="top" bgcolor="#FFFFFF">选择主页模板:</td>
  39. <td width="791" valign="top" bgcolor="#FFFFFF">
  40. <input name="templet" type="text" id="templet" style="width:300" value="<?php echo $row['templet']?>">
  41. <button class="btn btn-success btn-sm" type="button" name="set4" value=""
  42. onClick="SelectTemplets('form1.templet');">浏览...</button>
  43. </td>
  44. </tr>
  45. <tr>
  46. <td height="20" colspan="2" valign="top" bgcolor="#FFFFFF">
  47. 默认的情况下,生成的主页文件放在CMS的安装目录,如果您的CMS不是安装在网站根目录的,又想把主页创建到网站根目录,那么请用相对路径来表示“主页位置”。<br />
  48. 例:您的CMS安装在
  49. http://www.abc.com/DedeBIZ/ 目录,您想生成的主页为 http://www.abc.com/index.html,那么主页位置就应该用:
  50. “../index.html”。</td>
  51. </tr>
  52. <tr>
  53. <td height="20" valign="top" bgcolor="#FFFFFF">主页位置:</td>
  54. <td height="20" valign="top" bgcolor="#FFFFFF">
  55. <input name="position" type="text" id="position" value="<?php echo $row['position']?>" size="30">
  56. </td>
  57. </tr>
  58. <tr>
  59. <td height="20" valign="top" bgcolor="#FFFFFF">相关选项:</td>
  60. <td height="20" valign="top" bgcolor="#FFFFFF">
  61. <label><input name="saveset" type="radio" value="0" class="np">
  62. 不保存当前选项</label>
  63. <label><input name="saveset" type="radio" class="np" value="1" checked>
  64. 保存当前选项</label>
  65. </td>
  66. </tr>
  67. <tr>
  68. <td height="20" valign="top" bgcolor="#FFFFFF">首页模式:</td>
  69. <td height="20" valign="top" bgcolor="#FFFFFF">
  70. <label><input name="showmod" type="radio" value="0" class="np"
  71. <?php echo ($row['showmod']==0)? "checked='checked'" : "";?> />
  72. 动态浏览</label>
  73. <label><input name="showmod" type="radio" class="np" value="1"
  74. <?php echo ($row['showmod']==1)? "checked='checked'" : "";?> />
  75. 生成静态 (或者手动删除根目录下index.html文件)</label></td>
  76. </tr>
  77. <tr>
  78. <td height="20" colspan="2" valign="top" bgcolor="#dee2e6">
  79. 首页防篡改(主页位置更改请重新启动DedeBIZ商业组件)
  80. </td>
  81. </tr>
  82. <?php
  83. if (!empty($cfg_bizcore_appid) && !empty($cfg_bizcore_key)) {
  84. $client = new DedeBizClient($cfg_bizcore_hostname, $cfg_bizcore_port);
  85. $client->appid = $cfg_bizcore_appid;
  86. $client->key = $cfg_bizcore_key;
  87. $data = $client->AdminPWDExists();
  88. $data = json_decode($data->data);
  89. $rs = (array)($data->result);
  90. if($rs["admin_pwd_exists"] == "false") {?>
  91. <tr>
  92. <td height="20" valign="top" bgcolor="#FFFFFF">设置DedeBIZ操作密码:</td>
  93. <td height="20" valign="top" bgcolor="#FFFFFF">
  94. <input name="dedebiz_admin" type="password" id="dedebiz_admin" value="" size="30">
  95. 设定后所有的DedeBIZ涉及安全操作输入当前操作密码
  96. </td>
  97. </tr>
  98. <tr>
  99. <td height="20" valign="top" bgcolor="#FFFFFF">重复DedeBIZ操作密码:</td>
  100. <td height="20" valign="top" bgcolor="#FFFFFF">
  101. <input name="re_dedebiz_admin" type="password" id="re_dedebiz_admin" value="" size="30">
  102. </td>
  103. </tr>
  104. <?php }else{ ?>
  105. <tr>
  106. <td height="20" valign="top" bgcolor="#FFFFFF">DedeBIZ操作密码:</td>
  107. <td height="20" valign="top" bgcolor="#FFFFFF">
  108. <input name="dedebiz_admin" type="password" id="dedebiz_admin" value="" size="30">
  109. </td>
  110. </tr>
  111. <tr>
  112. <td height="20" valign="top" bgcolor="#FFFFFF">首页状态:</td>
  113. <td height="20" valign="top" bgcolor="#FFFFFF">
  114. <label><input name="lockindex" type="radio" class="np" value="unlock"
  115. <?php echo ($rs['index_lock_state']==true)? "checked='checked'" : "";?> />
  116. 解锁</label>
  117. <label><input name="lockindex" type="radio" value="lock" class="np"
  118. <?php echo ($row['index_lock_state']==false)? "checked='checked'" : "";?> />
  119. 锁定</label>
  120. </td>
  121. </tr>
  122. <?php
  123. }
  124. } else {
  125. ?>
  126. <tr>
  127. <td height="20" colspan="2" valign="top" bgcolor="#FFFFFF">
  128. 尚未开启DedeBIZ商业组件 <a class="btn btn-danger btn-sm" target="_blank" href="https://www.dedebiz.com/start?code=-1008">如何启动组件</a>
  129. </td>
  130. </tr>
  131. <?php
  132. }
  133. ?>
  134. <tr>
  135. <td height="31" colspan="2" bgcolor="#ffffff" align="center">&nbsp;&nbsp;
  136. <button name="view" class='btn btn-success' type="button" id="view"
  137. onClick="window.open('makehtml_homepage.php?dopost=view&templet='+form1.templet.value);">预览主页</button>
  138. <button type="button" onclick="htmlSubmit()" class='btn btn-success' name="Submit">更新主页HTML</button>
  139. &nbsp;
  140. </td>
  141. </tr>
  142. </form>
  143. <tr bgcolor="#F9FCEF">
  144. <td height="20" colspan="2">
  145. <table width="100%" class="table table-borderless">
  146. <tr>
  147. <td width="74%">进行状态: </td>
  148. <td width="26%" align="right">
  149. <script language='javascript'>
  150. function ResizeDiv(obj, ty) {
  151. if (ty == "+") document.all[obj].style.pixelHeight += 50;
  152. else if (document.all[obj].style.pixelHeight > 80) document.all[obj].style.pixelHeight = document.all[obj].style.pixelHeight - 50;
  153. }
  154. </script>
  155. [<a href='javascript:;' onClick="ResizeDiv('mdv','+');">增大</a>] [<a href='javascript:;' onClick="ResizeDiv('mdv','-');">缩小</a>]
  156. </td>
  157. </tr>
  158. </table>
  159. </td>
  160. </tr>
  161. <tr bgcolor="#FFFFFF">
  162. <td colspan="2" id="mtd">
  163. <div id='mdv' style='width:100%;height:350px;'>
  164. <iframe name="stafrm" frameborder="0" id="stafrm" width="100%" height="100%"></iframe>
  165. </div>
  166. </td>
  167. </tr>
  168. </table>
  169. </body>
  170. </html>