我需要页码,但似乎无法找到任何文档。如何在CakePHP视图中输出我当前的页面(使用PaginatorHelper)?
谢谢!
答案 0 :(得分:4)
$this->Paginator->current($model = null)
http://api.cakephp.org/class/paginator-helper#method-PaginatorHelpercurrent
答案 1 :(得分:1)
通过pr()提取$ this->请求后,我得到了这个解决方案
$ currentPage = $ this-> request-> paging [' Model'] [' page']
并将其展示 $ this-> set(' currentPage',$ currentPage)