去掉织梦搜索页翻页链接中的中括号“[]”

来源:互联网 发布:金策大数据分析系统 编辑:程序博客网 时间:2024/05/29 14:36

 首先,找到控制搜索页的php文件,位置在:include/arc.searchview.class.php
  在其中搜索//获得数字链接,代码大致如下:

        //获得数字链接        $listdd="";        $total_list = $list_len * 2 + 1;        if($this->PageNo >= $total_list)        {            $j = $this->PageNo - $list_len;            $total_list = $this->PageNo + $list_len;            if($total_list > $totalpage)            {                $total_list = $totalpage;            }        }        else        {            $j=1;            if($total_list > $totalpage)            {                $total_list = $totalpage;            }        }        for($j; $j<=$total_list; $j++)        {            if($j == $this->PageNo)            {                $listdd.= "<td>$j&nbsp;</td>\r\n";            }            else            {                $listdd.="<td><a href='".$purl."PageNo=$j'>[".$j."]</a>&nbsp;</td>\r\n";            }        }        $plist  =  "<table border='0' cellpadding='0' cellspacing='0'>\r\n";        $plist .= "<tr align='center' style='font-size:10pt'>\r\n";        $plist .= "<form name='pagelist' action='".$this->GetCurUrl()."'>$hidenform";        $plist .= $infos;        $plist .= $indexpage;        $plist .= $prepage;        $plist .= $listdd;        $plist .= $nextpage;        $plist .= $endpage;        if($totalpage>$total_list)        {            $plist.="<td width='38'><input type='text' name='PageNo' style='width:28px;height:14px' value='".$this->PageNo."' /></td>\r\n";            $plist.="<td width='30'><input type='submit' name='plistgo' value='GO' style='width:30px;height:22px;font-size:9pt' /></td>\r\n";        }        $plist .= "</form>\r\n</tr>\r\n</table>\r\n";        return $plist;    }

  在其中找到 $listdd.="<td><a href='".$purl."PageNo=$j'>[".$j."]</a>&nbsp;</td>\r\n";,把其中的[".$j."]替换成".$j."就可以了。如果想改其它东西,也可以看看这部分代码。

原创粉丝点击