应该把118行到131行替换为
}else{
$preRow = $this->nowPage-$this->rollPage;
if($preRow < 1){
$prePage = "<a href='".str_replace('__PAGE__',$preRow,$url)."' >上".$this->rollPage."页</a>";
}
$theFirst = "<a href='".str_replace('__PAGE__',1,$url)."' >".$this->config['first']."</a>";
}
if($nowCoolPage == $this->coolPages){
$nextPage = '';
$theEnd = '';
}else{
$nextRow = $this->nowPage+$this->rollPage;
$theEndRow = $this->totalPages;
if($theEndRow > $nextRow){
$nextPage = "<a href='".str_replace('__PAGE__',$nextRow,$url)."' >下".$this->rollPage."页</a>";
}
$theEnd = "<a href='".str_replace('__PAGE__',$theEndRow,$url)."' >".$this->config['last']."</a>";
}这样修改后,下午页大雨最大页数时就不会现实,上5页小于1时也不会显示,这样才合理。 最佳答案