一聚教程网:一个值得你收藏的教程网站

热门教程

DedeCms点击图片进入下一页,点击最后一页图片进入下一篇

时间:2022-06-25 16:45:19 编辑:袖梨 来源:一聚教程网

1、编辑打开include/arc.archives.class.php教程

2、查找“//解析模板,对内容里的变动进行赋值”在这段话上面添加以下代码

function clickpicnext($ismake=1,$aid,&$body)
{
global $cfg_rewrite;
if($this->nowpage!=$this->totalpage)
{
$lpage=$this->nowpage+1;
if($ismake=0)
{
$body=preg_replace("/<(img|img)(.*)(src|src)=["|'| ]{0,}((.*)>)/isu","点击图片,进入下一页
"."${0}"."",$body);
}
else
{
$pagelist=""."${0}"."";
if($cfg_rewrite == 'y')
{
$pagelist = str_replace(".php?aid=","-",$pagelist);
$pagelist = preg_replace("/&pageno=(d+)/i",'-.html',$pagelist);
}
$body=preg_replace("/<(img|img)(.*)(src|src)=["|'| ]{0,}((.*)>)/isu",$pagelist,$body);
}
}
else
{
$body=preg_replace("/<(img|img)(.*)(src|src)=["|'| ]{0,}((.*)>)/isu",$this->getprenext('imgnext'),$body);
}
return $body;
}

查找$this->fields[$this->splitpagefield] = $this->splitfields[$pageno - 1]; 在其下面添加


if($clickpicnext){
            $this->fields[$this->splitpagefield]=$this->fields[$this->splitpagefield];
            }else{
            $this->fields[$this->splitpagefield]=$this->clickpicnext($ismake,$this->fields['id'],$this->fields[$this->splitpagefield]);
            }

查找$this->prenext['next'] = "下一篇:{$nextrow['title']} ";在其下面添加

$this->prenext['imgnext'] =""."${0}"."";

查找$this->prenext['next'] = "下一篇:没有了 ";在其下面添加
$this->prenext['imgnext'] ="${0}";

查找

 else if($gtype=='imgnext')                  
{  
$rs =  $this->prenext['imgnext'];    
}

在其下面添加

 else if($gtype=='imgnext')
{
$rs = $this->prenext['imgnext'];
}

 

热门栏目