修改DedeCMS pagebreak標(biāo)簽 不列出全部頁
來源:程序員人生 發(fā)布時間:2014-04-27 04:30:43 閱讀次數(shù):2577次
需求:我的圖片集有幾百張,幻燈顯示會把所有的都列出來,影響美觀,如圖:
引用的內(nèi)容:[www.veryhuo.com]
$total_list=13; //顯示13個,6*2+1=13
if($nowPage >= $total_list) {
$i = $nowPage-6; //前后6個,(13-1)/ 2=6
$total_list = $nowPage+6; //前后6個,(13-1)/ 2=6
if($total_list >= $totalPage) $total_list = $totalPage;
}else{
$i=1;
if($total_list >= $totalPage) $total_list = $totalPage;
}
B、把“for($i=1;$i<=$totalPage;$i++)”,改成“for($i;$i<=$totalPage;$i++)”
2、查找“function GetPagebreak($totalPage,$nowPage,$aid)”(靜態(tài)頁面分頁函數(shù)函數(shù),大概在550行左右)
A、同上
B、同上
附件下載:091110114422.rar
相關(guān)文章:DedeCMS分頁太多 頁碼智能顯示的方法
生活不易,碼農(nóng)辛苦
如果您覺得本網(wǎng)站對您的學(xué)習(xí)有所幫助,可以手機(jī)掃描二維碼進(jìn)行捐贈