本文整理匯總了PHP中Zend_Db_Select::limitPage方法的典型用法代碼示例。如果您正苦於以下問題:PHP Zend_Db_Select::limitPage方法的具體用法?PHP Zend_Db_Select::limitPage怎麽用?PHP Zend_Db_Select::limitPage使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類Zend_Db_Select
的用法示例。
在下文中一共展示了Zend_Db_Select::limitPage方法的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: next
/**
* This returns the next chunk of database result objects.
*
* @return array|null Set of Omeka_Record instances, or null if none can be
* found.
* @author Eric Rochester <erochest@virginia.edu>
**/
public function next()
{
$this->pageNumber++;
$this->select->limitPage($this->pageNumber, $this->rowCount);
$rows = $this->table->fetchObjects($this->select, $this->params);
return $rows;
}
示例2: _renderLimit
/**
* Render sql select limit
*
* @return Varien_Data_Collection_Db
*/
protected function _renderLimit()
{
if ($this->_pageSize) {
$this->_select->limitPage($this->getCurPage(), $this->_pageSize);
}
return $this;
}
示例3: applyPagination
/**
* Apply pagination to a select object via the LIMIT and OFFSET clauses.
*
* @param Zend_Db_Select $select
* @param integer $limit Number of results per "page".
* @param integer|null $page Page to retrieve, first if omitted.
* @return Zend_Db_Select
*/
public function applyPagination($select, $limit, $page = null)
{
if ($page) {
$select->limitPage($page, $limit);
} else {
$select->limit($limit);
}
return $select;
}
示例4: limitPage
/**
* @return WeFlex_Db_Model
*/
public function limitPage($page, $rowCount)
{
$this->_selector->limitPage($page, $rowCount);
return $this;
}