Yusi.php 24 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466
  1. <?php
  2. $themename = $dname.'主题';
  3. $options = array(
  4. "d_description", "d_keywords", "d_tui", "d_sticky_b", "d_sticky_count", "d_linkpage_cat", "d_linkpage_cat_mine","d_tougao_b", "d_tougao_time", "d_tougao_mailto", "d_avatar_b", "d_avatarDate", "d_sideroll_b", "d_sideroll_1", "d_sideroll_2", "d_pingback_b", "d_autosave_b", "d_tqq_b", "d_tqq", "d_weibo_b", "d_weibo", "d_facebook_b", "d_facebook","d_google_b", "d_google", "d_twitter_b", "d_twitter", "d_rss","d_qqContact_b","d_qqContact","d_weixin_b","d_weixin","d_emailContact_b","d_emailContact", "d_track_b", "d_track", "d_headcode_b", "d_headcode", "d_footcode_b", "d_footcode", "d_adsite_01_b", "d_adsite_01", "d_adindex_02_b", "d_adindex_02", "d_adindex_01_b", "d_adindex_01", "d_adindex_03_b", "d_adindex_03", "d_adpost_01_b", "d_adpost_01", "d_adpost_02_b", "d_adpost_02", "d_adpost_03_b", "d_adpost_03", "d_sign_b", "d_jquerybom_b", "d_ajaxpager_b", "d_thumbnail_b", "d_bdshare_b", "d_related_count", "d_post_views_b", "d_post_author_b", "d_post_comment_b", "d_post_time_b","hot_list_title","hot_list_number","hot_list_date","hot_list_check","d_post_like_b","d_singleMenu_b","Mobiled_adindex_02_b","Mobiled_adindex_02","Mobiled_adpost_01_b","Mobiled_adpost_01","Mobiled_adpost_02_b","Mobiled_adpost_02","d_spamComments_b"
  5. );
  6. function mytheme_add_admin() {
  7. global $themename, $options;
  8. if ( $_GET['page'] == basename(__FILE__) ) {
  9. if ( 'save' == $_REQUEST['action'] ) {
  10. foreach ($options as $value) {
  11. update_option( $value, $_REQUEST[ $value ] );
  12. }
  13. header("Location: admin.php?page=Yusi.php&saved=true");
  14. die;
  15. }
  16. }
  17. add_theme_page($themename." Options", $themename."设置", 'edit_themes', basename(__FILE__), 'mytheme_admin');
  18. }
  19. function mytheme_admin() {
  20. global $themename, $options;
  21. $i=0;
  22. if ( $_REQUEST['saved'] ) echo '<div class="updated settings-error"><p>'.$themename.'修改已保存</p></div>';
  23. ?>
  24. <div class="wrap d_wrap">
  25. <link rel="stylesheet" href="<?php bloginfo('template_url') ?>/admin/admin.css"/>
  26. <h2><?php echo $themename; ?>设置
  27. <span class="d_themedesc">发布来源:<a href="http://www.yusi123.com/" target="_blank">欲思博客</a> &nbsp;&nbsp; <a href="http://yusi123.com/3233.html" target="_blank">访问<?php echo $themename; ?>主页</a></span><span style="font-size:16px;color: rgb(245, 99, 99);padding-left:20px;">觉得主题不错?支持一下我继续更新吧 -><a href="http://yusi123.com/pay" target="_blank">捐赠</a></span>
  28. </h2>
  29. <form method="post" class="d_formwrap">
  30. <table>
  31. <thead>
  32. <tr>
  33. <th width="200"></th>
  34. <th></th>
  35. </tr>
  36. </thead>
  37. <tr>
  38. <td class="d_tit">网站描述</td>
  39. <td>
  40. <input class="ipt-b" type="text" id="d_description" name="d_description" value="<?php echo dopt('d_description'); ?>">
  41. </td>
  42. </tr>
  43. <tr>
  44. <td class="d_tit">网站关键字</td>
  45. <td>
  46. <input class="ipt-b" type="text" id="d_keywords" name="d_keywords" value="<?php echo dopt('d_keywords'); ?>">
  47. </td>
  48. </tr>
  49. <tr>
  50. <td class="d_tit">最新消息</td>
  51. <td>
  52. <textarea name="d_tui" id="d_tui" type="textarea" rows=""><?php echo dopt('d_tui'); ?></textarea>
  53. <span class="d_tip">最新消息显示在全站导航条下方,非常给力的推广位置</span>
  54. </td>
  55. </tr>
  56. <tr>
  57. <td class="d_tit">首页置顶推荐幻灯片</td>
  58. <td>
  59. <label class="checkbox inline">
  60. <input type="checkbox" id="d_sticky_b" name="d_sticky_b" <?php if(dopt('d_sticky_b')) echo 'checked="checked"' ?>>开启
  61. </label>
  62. 显示<input class="d_num" name="d_sticky_count" id="d_sticky_count" type="number" value="<?php echo dopt('d_sticky_count'); ?>">条 默认4条
  63. &nbsp; &nbsp;
  64. <span class="d_tip">开启后请确保您的后台-文章中设置了4篇以上的置顶文章,并且文章第一张图片像素为716*297</span>
  65. </td>
  66. </tr>
  67. <tr>
  68. <td class="d_tit">友情链接页面</td>
  69. <td>
  70. <label class="checkbox inline">
  71. 只显示分类ID为 <input name="d_linkpage_cat" id="d_linkpage_cat" type="text" value="<?php echo dopt('d_linkpage_cat'); ?>"> 的链接(id之间用英文逗号隔开),默认显示全部,如果要显示带头像的友情链接,请在notes中添加上链接邮箱
  72. &nbsp; &nbsp;
  73. </label>
  74. </td>
  75. </tr>
  76. <tr>
  77. <td class="d_tit">我的链接</td>
  78. <td>
  79. <label class="checkbox inline">
  80. 我的分类ID为 <input name="d_linkpage_cat_mine" id="d_linkpage_cat_mine" type="text" value="<?php echo dopt('d_linkpage_cat_mine'); ?>">
  81. &nbsp; &nbsp;
  82. </label>
  83. </td>
  84. </tr>
  85. <tr>
  86. <td class="d_tit">文章无特色图时不显示默认缩略图</td>
  87. <td>
  88. <label class="checkbox inline">
  89. <input type="checkbox" id="d_thumbnail_b" name="d_thumbnail_b" <?php if(dopt('d_thumbnail_b')) echo 'checked="checked"' ?>>开启
  90. </label>
  91. 列表Ajax加载分页内容
  92. <label class="checkbox inline">
  93. <input type="checkbox" id="d_ajaxpager_b" name="d_ajaxpager_b" <?php if(dopt('d_ajaxpager_b')) echo 'checked="checked"' ?>>开启
  94. </label>
  95. 文章页顶部面包屑导航 <label class="checkbox inline">
  96. <input type="checkbox" id="d_singleMenu_b" name="d_singleMenu_b" <?php if(dopt('d_singleMenu_b')) echo 'checked="checked"' ?>>开启
  97. </label>
  98. </td>
  99. </tr>
  100. <tr>
  101. <td class="d_tit">热门排行</td>
  102. <td>
  103. <label class="checkbox inline">
  104. <input type="checkbox" id="hot_list_check" name="hot_list_check" <?php if(dopt('hot_list_check')) echo 'checked="checked"' ?>>开启
  105. </label>
  106. 显示天数 <input class="hot_list_date" name="hot_list_date" id="hot_list_date" type="number" value="<?php echo dopt('hot_list_date'); ?>"> 天(默认7)
  107. 显示数量 <input class="hot_list_number" name="hot_list_number" id="hot_list_number" type="number" value="<?php echo dopt('hot_list_number'); ?>">条(默认10)
  108. &nbsp;&nbsp; 名称 <input class="d_inp_short" name="hot_list_title" id="hot_list_title" type="text" value="<?php echo dopt('hot_list_title'); ?>">
  109. </td>
  110. </tr>
  111. <tr>
  112. <td class="d_tit">列表文章属性开关</td>
  113. <td>
  114. <label class="checkbox inline">
  115. <input type="checkbox" id="d_post_views_b" name="d_post_views_b" <?php if(dopt('d_post_views_b')) echo 'checked="checked"' ?>>不显示访客数
  116. </label> &nbsp; &nbsp;
  117. <label class="checkbox inline">
  118. <input type="checkbox" id="d_post_author_b" name="d_post_author_b" <?php if(dopt('d_post_author_b')) echo 'checked="checked"' ?>>不显示作者
  119. </label> &nbsp; &nbsp;
  120. <label class="checkbox inline">
  121. <input type="checkbox" id="d_post_comment_b" name="d_post_comment_b" <?php if(dopt('d_post_comment_b')) echo 'checked="checked"' ?>>不显示评论数
  122. </label> &nbsp; &nbsp;
  123. <label class="checkbox inline">
  124. <input type="checkbox" id="d_post_time_b" name="d_post_time_b" <?php if(dopt('d_post_time_b')) echo 'checked="checked"' ?>>不显示时间
  125. </label> &nbsp; &nbsp;
  126. <label class="checkbox inline">
  127. <input type="checkbox" id="d_post_like_b" name="d_post_like_b" <?php if(dopt('d_post_like_b')) echo 'checked="checked"' ?>>不显示喜欢
  128. </label>
  129. </td>
  130. </tr>
  131. </td>
  132. </tr>
  133. <tr>
  134. <td class="d_tit">文章页 - 相关文章显示条数</td>
  135. <td>
  136. 显示<input class="d_num" name="d_related_count" id="d_related_count" type="number" value="<?php echo dopt('d_related_count'); ?>">条 默认 8
  137. </td>
  138. </tr>
  139. <tr>
  140. <td class="d_tit">jQuery底部加载</td>
  141. <td>
  142. <label class="checkbox inline">
  143. <input type="checkbox" id="d_jquerybom_b" name="d_jquerybom_b" <?php if(dopt('d_jquerybom_b')) echo 'checked="checked"' ?>>开启
  144. </label>
  145. <span class="d_tip">jQuery默认在head区域加载,如果需要页面载入加速,请开启,但是有可能影响部分依赖jQuery的插件失效。</span>
  146. </td>
  147. </tr>
  148. <tr>
  149. <td class="d_tit">用户登录信息和分享</td>
  150. <td>
  151. <label class="checkbox inline">
  152. <input type="checkbox" id="d_sign_b" name="d_sign_b" <?php if(dopt('d_sign_b')) echo 'checked="checked"' ?>>开启用户登录信息
  153. </label>
  154. <label class="checkbox inline">
  155. <input type="checkbox" id="d_bdshare_b" name="d_bdshare_b" <?php if(dopt('d_bdshare_b')) echo 'checked="checked"' ?>>开启百度分享
  156. </label>
  157. </td>
  158. </tr>
  159. <tr>
  160. <td class="d_tit">投稿</td>
  161. <td>
  162. <label class="checkbox inline">
  163. <input type="checkbox" id="d_tougao_b" name="d_tougao_b" <?php if(dopt('d_tougao_b')) echo 'checked="checked"' ?>>开启
  164. </label>
  165. 投稿时间间隔 <input class="d_num" name="d_tougao_time" id="d_tougao_time" type="number" value="<?php echo dopt('d_tougao_time'); ?>"> 秒,默认:240
  166. &nbsp; &nbsp;
  167. 投稿提醒邮箱 <input name="d_tougao_mailto" id="d_tougao_mailto" type="text" value="<?php echo dopt('d_tougao_mailto'); ?>">
  168. </td>
  169. </tr>
  170. <tr>
  171. <td class="d_tit">评论头像缓存</td>
  172. <td>
  173. <label class="checkbox inline">
  174. <input type="checkbox" id="d_avatar_b" name="d_avatar_b" <?php if(dopt('d_avatar_b')) echo 'checked="checked"' ?>>开启
  175. </label>
  176. <label class="d_number">
  177. 缓存
  178. <input class="d_num " name="d_avatarDate" id="d_avatarDate" type="number" value="<?php if( dopt('d_avatarDate') ) echo dopt('d_avatarDate'); else echo '15'; ?>"> 天
  179. &nbsp; &nbsp;
  180. 开启后请确保网站根目录(与wp-content平级)有avatar文件夹,且权限设置成777
  181. <br>
  182. <span class="d_tip">缓存头像有利于头像加载和防备Gravatar头像站点被墙;如有报错等异常,请关闭,可能你的主机不支持</span>
  183. </label>
  184. </td>
  185. </tr>
  186. <tr>
  187. <td class="d_tit">评论内容过滤</td>
  188. <td>
  189. <label class="checkbox inline">
  190. <input type="checkbox" id="d_spamComments_b" name="d_spamComments_b" <?php if(dopt('d_spamComments_b')) echo 'checked="checked"' ?>>开启
  191. </label>
  192. <span class="d_tip">开启后,会禁止有日文字符和纯英文的评论,不对外的建议开启。</span>
  193. </td>
  194. </tr>
  195. <tr>
  196. <td class="d_tit">侧栏模块固定</td>
  197. <td>
  198. <label class="checkbox inline">
  199. <input type="checkbox" id="d_sideroll_b" name="d_sideroll_b" <?php if(dopt('d_sideroll_b')) echo 'checked="checked"' ?>>开启
  200. </label>
  201. <label class="d_number">
  202. 滚动时 固定侧栏的 第
  203. <input class="d_num " name="d_sideroll_1" id="d_sideroll_1" type="number" value="<?php echo dopt('d_sideroll_1'); ?>"> 个模块
  204. </label>
  205. <label class="d_number">
  206. <input class="d_num " name="d_sideroll_2" id="d_sideroll_2" type="number" value="<?php echo dopt('d_sideroll_2'); ?>"> 个模块
  207. </label>
  208. </td>
  209. </tr>
  210. <tr>
  211. <td class="d_tit">禁止站内文章Pingback</td>
  212. <td>
  213. <label class="checkbox inline">
  214. <input type="checkbox" id="d_pingback_b" name="d_pingback_b" <?php if(dopt('d_pingback_b')) echo 'checked="checked"' ?>>开启
  215. &nbsp; &nbsp;
  216. <span class="d_tip">开启后,不会发送站内Pingback,建议开启</span>
  217. </label>
  218. </td>
  219. </tr>
  220. <tr>
  221. <td class="d_tit">禁止后台编辑时自动保存</td>
  222. <td>
  223. <label class="checkbox inline">
  224. <input type="checkbox" id="d_autosave_b" name="d_autosave_b" <?php if(dopt('d_autosave_b')) echo 'checked="checked"' ?>>开启
  225. &nbsp; &nbsp;
  226. <span class="d_tip">开启后,后台编辑文章时候不会定时保存,有效缩减数据库存储量;但是,一般不建议开启,除非你的数据库容量很小</span>
  227. </label>
  228. </td>
  229. </tr>
  230. <tr>
  231. <td class="d_tit">腾讯微博</td>
  232. <td>
  233. <label class="checkbox inline">
  234. <input type="checkbox" id="d_tqq_b" name="d_tqq_b" <?php if(dopt('d_tqq_b')) echo 'checked="checked"' ?>>开启
  235. </label>
  236. 网址:<input class="d_inp_short" name="d_tqq" id="d_tqq" type="text" value="<?php echo dopt('d_tqq'); ?>">
  237. </td>
  238. </tr>
  239. <tr>
  240. <td class="d_tit">新浪微博</td>
  241. <td>
  242. <label class="checkbox inline">
  243. <input type="checkbox" id="d_weibo_b" name="d_weibo_b" <?php if(dopt('d_weibo_b')) echo 'checked="checked"' ?>>开启
  244. </label>
  245. 网址:<input class="d_inp_short" name="d_weibo" id="d_weibo" type="text" value="<?php echo dopt('d_weibo'); ?>">
  246. </td>
  247. </tr>
  248. <tr>
  249. <td class="d_tit">腾讯微信</td>
  250. <td>
  251. <label class="checkbox inline">
  252. <input type="checkbox" id="d_weixin_b" name="d_weixin_b" <?php if(dopt('d_weixin_b')) echo 'checked="checked"' ?>>开启
  253. </label>
  254. 订阅号:<input class="d_inp_short" name="d_weixin" id="d_weixin" type="text" value="<?php echo dopt('d_weixin'); ?>"><span class="d_tip">微信图片直接替换主题同名weixin.gif图片即可。</span>
  255. </td>
  256. </tr>
  257. <tr>
  258. <td class="d_tit">QQ联系代码</td>
  259. <td>
  260. <label class="checkbox inline">
  261. <input type="checkbox" id="d_qqContact_b" name="d_qqContact_b" <?php if(dopt('d_qqContact_b')) echo 'checked="checked"' ?>>开启
  262. </label>
  263. 代码:<input class="d_inp_short" name="d_qqContact" id="d_qqContact" type="text" value="<?php echo dopt('d_qqContact'); ?>">
  264. </td>
  265. </tr>
  266. <tr>
  267. <td class="d_tit">Email</td>
  268. <td>
  269. <label class="checkbox inline">
  270. <input type="checkbox" id="d_emailContact_b" name="d_emailContact_b" <?php if(dopt('d_emailContact_b')) echo 'checked="checked"' ?>>开启
  271. </label>
  272. 网址:<input class="d_inp_short" name="d_emailContact" id="d_emailContact" type="text" value="<?php echo dopt('d_emailContact'); ?>">
  273. </td>
  274. </tr>
  275. <tr>
  276. <td class="d_tit">Facebook</td>
  277. <td>
  278. <label class="checkbox inline">
  279. <input type="checkbox" id="d_facebook_b" name="d_facebook_b" <?php if(dopt('d_facebook_b')) echo 'checked="checked"' ?>>开启
  280. </label>
  281. 网址:<input class="d_inp_short" name="d_facebook" id="d_facebook" type="text" value="<?php echo dopt('d_facebook'); ?>">
  282. </td>
  283. </tr>
  284. <tr>
  285. <td class="d_tit">Google+</td>
  286. <td>
  287. <label class="checkbox inline">
  288. <input type="checkbox" id="d_google_b" name="d_google_b" <?php if(dopt('d_google_b')) echo 'checked="checked"' ?>>开启
  289. </label>
  290. 网址:<input class="d_inp_short" name="d_google" id="d_google" type="text" value="<?php echo dopt('d_google'); ?>">
  291. </td>
  292. </tr>
  293. <tr>
  294. <td class="d_tit">Twitter</td>
  295. <td>
  296. <label class="checkbox inline">
  297. <input type="checkbox" id="d_twitter_b" name="d_twitter_b" <?php if(dopt('d_twitter_b')) echo 'checked="checked"' ?>>开启
  298. </label>
  299. 网址:<input class="d_inp_short" name="d_twitter" id="d_twitter" type="text" value="<?php echo dopt('d_twitter'); ?>">
  300. </td>
  301. </tr>
  302. <tr>
  303. <td class="d_tit">RSS订阅地址</td>
  304. <td>
  305. <input class="d_inp_short" name="d_rss" id="d_rss" type="text" value="<?php echo dopt('d_rss'); ?>">
  306. <span class="d_tip">可以是其他订阅托管站点的地址。边栏只能选择六个社交账户,否则会错位。</span>
  307. </td>
  308. </tr>
  309. <tr>
  310. <td class="d_tit">流量统计代码</td>
  311. <td>
  312. <label class="checkbox inline">
  313. <input type="checkbox" id="d_track_b" name="d_track_b" <?php if(dopt('d_track_b')) echo 'checked="checked"' ?>>开启
  314. <span class="d_tip">统计网站流量,推荐使用百度统计,国内比较优秀且速度快;还可使用Google统计、CNZZ等</span>
  315. </label>
  316. <textarea name="d_track" id="d_track" type="textarea" rows="2"><?php echo dopt('d_track'); ?></textarea>
  317. </td>
  318. </tr>
  319. <tr>
  320. <td class="d_tit">页面头部公共代码</td>
  321. <td>
  322. <label class="checkbox inline">
  323. <input type="checkbox" id="d_headcode_b" name="d_headcode_b" <?php if(dopt('d_headcode_b')) echo 'checked="checked"' ?>>开启
  324. <span class="d_tip">会自动出现在页面头部(head区域),可放置广告代码等自定义(css或js)的全局代码块</span>
  325. </label>
  326. <textarea name="d_headcode" id="d_headcode" type="textarea" rows="2"><?php echo dopt('d_headcode'); ?></textarea>
  327. </td>
  328. </tr>
  329. <tr>
  330. <td class="d_tit">页面底部公共代码</td>
  331. <td>
  332. <label class="checkbox inline">
  333. <input type="checkbox" id="d_footcode_b" name="d_footcode_b" <?php if(dopt('d_footcode_b')) echo 'checked="checked"' ?>>开启
  334. <span class="d_tip">同上,但是在全站页面底部出现</span>
  335. </label>
  336. <textarea name="d_footcode" id="d_footcode" type="textarea" rows="2"><?php echo dopt('d_footcode'); ?></textarea>
  337. </td>
  338. </tr>
  339. <tr>
  340. <td class="d_tit">广告:全站 - 导航下横幅</td>
  341. <td>
  342. <label class="checkbox inline">
  343. <input type="checkbox" id="d_adsite_01_b" name="d_adsite_01_b" <?php if(dopt('d_adsite_01_b')) echo 'checked="checked"' ?>>开启
  344. <span class="d_tip">广告区域,任意联盟广告和自定义广告的代码均可,下同</span>
  345. </label>
  346. <textarea name="d_adsite_01" id="d_adsite_01" type="textarea" rows=""><?php echo dopt('d_adsite_01'); ?></textarea>
  347. </td>
  348. </tr>
  349. <tr>
  350. <td class="d_tit">广告:全站正文列表最前</td>
  351. <td>
  352. <label class="checkbox inline">
  353. <input type="checkbox" id="d_adindex_02_b" name="d_adindex_02_b" <?php if(dopt('d_adindex_02_b')) echo 'checked="checked"' ?>>开启
  354. </label>
  355. <textarea name="d_adindex_02" id="d_adindex_02" type="textarea" rows=""><?php echo dopt('d_adindex_02'); ?></textarea>
  356. </td>
  357. </tr>
  358. <tr>
  359. <td class="d_tit">广告:首页 - 导航下横幅</td>
  360. <td>
  361. <label class="checkbox inline">
  362. <input type="checkbox" id="d_adindex_01_b" name="d_adindex_01_b" <?php if(dopt('d_adindex_01_b')) echo 'checked="checked"' ?>>开启
  363. </label>
  364. <textarea name="d_adindex_01" id="d_adindex_01" type="textarea" rows=""><?php echo dopt('d_adindex_01'); ?></textarea>
  365. </td>
  366. </tr>
  367. <tr>
  368. <td class="d_tit">广告:首页 - 正文最前上</td>
  369. <td>
  370. <label class="checkbox inline">
  371. <input type="checkbox" id="d_adindex_03_b" name="d_adindex_03_b" <?php if(dopt('d_adindex_03_b')) echo 'checked="checked"' ?>>开启
  372. </label>
  373. <textarea name="d_adindex_03" id="d_adindex_03" type="textarea" rows=""><?php echo dopt('d_adindex_03'); ?></textarea>
  374. </td>
  375. </tr>
  376. <tr>
  377. <td class="d_tit">广告:文章页 - 页面标题下</td>
  378. <td>
  379. <label class="checkbox inline">
  380. <input type="checkbox" id="d_adpost_01_b" name="d_adpost_01_b" <?php if(dopt('d_adpost_01_b')) echo 'checked="checked"' ?>>开启
  381. </label>
  382. <textarea name="d_adpost_01" id="d_adpost_01" type="textarea" rows=""><?php echo dopt('d_adpost_01'); ?></textarea>
  383. </td>
  384. </tr>
  385. <tr>
  386. <td class="d_tit">广告:文章页 - 相关文章下</td>
  387. <td>
  388. <label class="checkbox inline">
  389. <input type="checkbox" id="d_adpost_02_b" name="d_adpost_02_b" <?php if(dopt('d_adpost_02_b')) echo 'checked="checked"' ?>>开启
  390. </label>
  391. <textarea name="d_adpost_02" id="d_adpost_02" type="textarea" rows=""><?php echo dopt('d_adpost_02'); ?></textarea>
  392. </td>
  393. </tr>
  394. <tr>
  395. <td class="d_tit">广告:文章页 - 网友评论下</td>
  396. <td>
  397. <label class="checkbox inline">
  398. <input type="checkbox" id="d_adpost_03_b" name="d_adpost_03_b" <?php if(dopt('d_adpost_03_b')) echo 'checked="checked"' ?>>开启
  399. </label>
  400. <textarea name="d_adpost_03" id="d_adpost_03" type="textarea" rows=""><?php echo dopt('d_adpost_03'); ?></textarea>
  401. </td>
  402. </tr>
  403. <tr>
  404. <td class="d_tit">手机广告:全站正文列表最前</td>
  405. <td>
  406. <label class="checkbox inline">
  407. <input type="checkbox" id="Mobiled_adindex_02_b" name="Mobiled_adindex_02_b" <?php if(dopt('Mobiled_adindex_02_b')) echo 'checked="checked"' ?>>开启 <span class="d_tip">手机广告只适合在手机中投放。例如百度联盟移动广告,PC端不会显示。下同。</span>
  408. </label>
  409. <textarea name="Mobiled_adindex_02" id="Mobiled_adindex_02" type="textarea" rows=""><?php echo dopt('Mobiled_adindex_02'); ?></textarea>
  410. </td>
  411. </tr>
  412. <tr>
  413. <td class="d_tit">手机广告:文章页 - 页面标题下</td>
  414. <td>
  415. <label class="checkbox inline">
  416. <input type="checkbox" id="Mobiled_adpost_01_b" name="Mobiled_adpost_01_b" <?php if(dopt('Mobiled_adpost_01_b')) echo 'checked="checked"' ?>>开启
  417. </label>
  418. <textarea name="Mobiled_adpost_01" id="Mobiled_adpost_01" type="textarea" rows=""><?php echo dopt('Mobiled_adpost_01'); ?></textarea>
  419. </td>
  420. </tr>
  421. <tr>
  422. <td class="d_tit">手机广告:文章页 - 相关文章下</td>
  423. <td>
  424. <label class="checkbox inline">
  425. <input type="checkbox" id="Mobiled_adpost_02_b" name="Mobiled_adpost_02_b" <?php if(dopt('Mobiled_adpost_02_b')) echo 'checked="checked"' ?>>开启
  426. </label>
  427. <textarea name="Mobiled_adpost_02" id="Mobiled_adpost_02" type="textarea" rows=""><?php echo dopt('Mobiled_adpost_02'); ?></textarea>
  428. </td>
  429. </tr>
  430. <tr>
  431. <td class="d_tit"></td>
  432. <td>
  433. <div class="d_desc">
  434. <input class="button-primary" name="save" type="submit" value="保存设置">
  435. </div>
  436. <input type="hidden" name="action" value="save">
  437. </td>
  438. </tr>
  439. </table>
  440. </form>
  441. </div>
  442. <script>
  443. var aaa = []
  444. jQuery('.d_wrap input, .d_wrap textarea').each(function(e){
  445. if( jQuery(this).attr('id') ) aaa.push( jQuery(this).attr('id') )
  446. })
  447. console.log( aaa )
  448. </script>
  449. <?php } ?>
  450. <?php add_action('admin_menu', 'mytheme_add_admin');?>