|
现在,在置顶操作管理里面添加了当前主题所在版块名称,这不是主要的,关键还是想彻底解决问题。通过审查元素,我们看到下面代码里面的“defaultSelForums”似乎是没有问题的,能够获取到的内容为“0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,”。但这些数字到底对应什么呢?索引吗?因为通过后台查看版块fid,从1到50,少了8、30和31,也是47个。但不确定,到底是不是版块的数组索引。 - <tr class="tr3 vt" id="forumsDiv" style="display: none">
- <td>选择置顶版块:<br>(按Ctrl可多选)</td>
- <th>
- <input type="hidden" value="" name="defaultSelForums" id="defaultSelForums"/>
- <select multiple="multiple" size="10" name="selForums[]" id="selForums" style="min-width: 300px;" class="select_wa"></select>
- </th>
- </tr>
搜索“defaultSelForums”,除了模板文件(mawhole.htm和ajax_mawhole.htm)上面代码中有两处外,就是这部分代码的上面还有一处:var defaultSelF = getObj('defaultSelForums');共三处;mawhole.php文件中共有两处: - } else {
- PostCheck();
- S::gp(array('topped', 'ifmsg', 'timelimit', 'nextto', 'selForums', 'defaultSelForums'));
- (is_null($topped)) && Showmsg('请选择置顶操作管理选项');
- $topped = intval($topped);
- $pwTopped = $isGM ? '3' : pwRights($isBM, 'topped');
- if ($topped > $pwTopped) {
- Showmsg('masigle_top');
- }
- empty($selForums) && $selForums = explode(',', trim($defaultSelForums, ','));
- if (empty($selForums)) {
- Showmsg('masigle_top_error');
- }
|