source/Application/Component/Locator.php
protected function _findActPageNumber($iPageNr, $oIdList = null, $oArticle = null)
    {
        //page number
        $iPageNr = (int) $iPageNr;

        // maybe there is no page number passed, but we still can find the position in id's list
        if (!$iPageNr && $oIdList && $oArticle) {
            $iNrofCatArticles = (int) \OxidEsales\Eshop\Core\Registry::getConfig()->getConfigParam('iNrofCatArticles');
            $iNrofCatArticles = $iNrofCatArticles ? $iNrofCatArticles : 1;
            $sParentIdField = 'oxarticles__oxparentid';
            $sArticleId = $oArticle->$sParentIdField->value ? $oArticle->$sParentIdField->value : $oArticle->getId();
            $iPos = \OxidEsales\Eshop\Core\Registry::getUtils()->arrayStringSearch($sArticleId, $oIdList->arrayKeys());
            $iPageNr = floor($iPos / $iNrofCatArticles);
        }

        return $iPageNr;
    }
protected function _findActPageNumber($iPageNr, $oIdList = null, $oArticle = null)
    {
        //page number
        $iPageNr = (int) $iPageNr;

        // maybe there is no page number passed, but we still can find the position in id's list
        if (!$iPageNr && $oIdList && $oArticle) {
            $iNrofCatArticles = (int) \OxidEsales\Eshop\Core\Registry::getConfig()->getConfigParam('iNrofCatArticles');
            $iNrofCatArticles = $iNrofCatArticles ? $iNrofCatArticles : 1;
            $sParentIdField = 'oxarticles__oxparentid';
            $sArticleId = $oArticle->$sParentIdField->value ? $oArticle->$sParentIdField->value : $oArticle->getId();
            $iPos = \OxidEsales\Eshop\Core\Registry::getUtils()->arrayStringSearch($sArticleId, $oIdList->arrayKeys());
            $iPageNr = floor($iPos / $iNrofCatArticles);
        }

        return $iPageNr;
    }
protected function _findActPageNumber ( $ iPageNr , $ oIdList = null , $ oArticle = null ) { //page number $ iPageNr = ( int ) $ iPageNr ; // maybe there is no page number passed, but we still can find the position in id's list if ( ! $ iPageNr && $ oIdList && $ oArticle ) { $ iNrofCatArticles = ( int ) \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) -> getConfigParam ( 'iNrofCatArticles' ) ; $ iNrofCatArticles = $ iNrofCatArticles ? $ iNrofCatArticles : 1 ; $ sParentIdField = 'oxarticles__oxparentid' ; $ sArticleId = $ oArticle -> $ sParentIdField -> value ? $ oArticle -> $ sParentIdField -> value : $ oArticle -> getId ( ) ; $ iPos = \ OxidEsales \ Eshop \ Core \ Registry :: getUtils ( ) -> arrayStringSearch ( $ sArticleId , $ oIdList -> arrayKeys ( ) ) ; $ iPageNr = floor ( $ iPos / $ iNrofCatArticles ) ; } return $ iPageNr ; }
If page number is not passed trying to fetch it from list of ids. To search
for position in list, article ids list and current article id must be passed

@param int                                         $iPageNr  current page number (user defined or passed by request)
@param \OxidEsales\Eshop\Core\Model\ListModel      $oIdList  list of article ids (optional)
@param \OxidEsales\Eshop\Application\Model\Article $oArticle active article id (optional)

@return int
If page number is not passed trying to fetch it from list of ids . To search for position in list article ids list and current article id must be passed