本文整理汇总了PHP中oxUBase::_addPageNrParam方法的典型用法代码示例。如果您正苦于以下问题:PHP oxUBase::_addPageNrParam方法的具体用法?PHP oxUBase::_addPageNrParam怎么用?PHP oxUBase::_addPageNrParam使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类oxUBase
的用法示例。
在下文中一共展示了oxUBase::_addPageNrParam方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: _addPageNrParam
/**
* Adds page number parameter to current Url and returns formatted url
*
* @param string $sUrl url to append page numbers
* @param int $iPage current page number
* @param int $iLang requested language
*
* @return string
*/
protected function _addPageNrParam($sUrl, $iPage, $iLang = null)
{
if (oxUtils::getInstance()->seoIsActive() && ($oRecomm = $this->getActiveRecommList())) {
if ($iPage) {
// only if page number > 0
$sUrl = $oRecomm->getBaseSeoLink($iLang, $iPage);
}
} else {
$sUrl = oxUBase::_addPageNrParam($sUrl, $iPage, $iLang);
}
return $sUrl;
}
示例2: _addPageNrParam
/**
* Modifies url by adding page parameters. When seo is on, url is additionally
* formatted by SEO engine
*
* @param string $sUrl current url
* @param int $iPage page number
* @param int $iLang active language id
*
* @return string
*/
protected function _addPageNrParam($sUrl, $iPage, $iLang = null)
{
if (oxRegistry::getUtils()->seoIsActive() && ($oVendor = $this->getActVendor())) {
if ($iPage) {
// only if page number > 0
$sUrl = $oVendor->getBaseSeoLink($iLang, $iPage);
}
} else {
$sUrl = oxUBase::_addPageNrParam($sUrl, $iPage, $iLang);
}
return $sUrl;
}
示例3: _addPageNrParam
/**
* Adds page number parameter to current Url and returns formatted url
*
* @param string $sUrl url to append page numbers
* @param int $iPage current page number
* @param int $iLang requested language
*
* @return string
*/
protected function _addPageNrParam($sUrl, $iPage, $iLang = null)
{
$sSeoUrl = $blSeo = oxRegistry::getUtils()->seoIsActive();
if ($blSeo && ($sTag = $this->getTag())) {
if ($iPage && ($sSeoUrl = oxRegistry::get("oxSeoEncoderTag")->getTagPageUrl($sTag, $iPage, $iLang))) {
// only if page number > 0
$sUrl = $sSeoUrl;
}
}
return !$blSeo || !$sSeoUrl ? oxUBase::_addPageNrParam($sUrl, $iPage, $iLang) : $sUrl;
}
示例4: _addPageNrParam
/**
* Adds page number parameter to current Url and returns formatted url
*
* @param string $url Url to append page numbers
* @param int $currentPage Current page number
* @param int $languageId Requested language
*
* @return string
*/
protected function _addPageNrParam($url, $currentPage, $languageId = null)
{
if (oxRegistry::getUtils()->seoIsActive() && ($category = $this->getActiveCategory())) {
if ($currentPage) {
// only if page number > 0
$url = $category->getBaseSeoLink($languageId, $currentPage);
}
} else {
$url = parent::_addPageNrParam($url, $currentPage, $languageId);
}
return $url;
}
示例5: _addPageNrParam
/**
* Adds page number parameter to current Url and returns formatted url
*
* @param string $sUrl url to append page numbers
* @param int $iPage current page number
* @param int $iLang requested language
*
* @return string
*/
protected function _addPageNrParam($sUrl, $iPage, $iLang = null)
{
if (oxRegistry::getUtils()->seoIsActive() && ($oCategory = $this->getActiveCategory())) {
if ($iPage) {
// only if page number > 0
$sUrl = $oCategory->getBaseSeoLink($iLang, $iPage);
}
} else {
$sUrl = parent::_addPageNrParam($sUrl, $iPage, $iLang);
}
return $sUrl;
}