Example #1
0
 public function getPageUrl($page)
 {
     //support of Mana_Filters
     if (Mage::helper('core')->isModuleEnabled('Mana_Filters') && Mage::helper('seo')->getFullActionCode() == 'catalog_category_view') {
         return parent::getPageUrl($page);
     }
     //support for Amasty Landing Pages
     if ($identifier = Mage::helper('seo')->isOnLandingPage()) {
         return $this->getParentBlock()->getPagerUrl(array($this->getPageVarName() => $page));
     }
     //support of TM_Attributepages, Fishpig_AttributeSplash and Magestore_Shopbybrand
     $excludedActions = array('attributepages_page_view', 'attributesplash_page_view', 'splash_page_view', 'brand_index_view');
     if (in_array(Mage::helper('seo')->getFullActionCode(), $actionArray)) {
         return parent::getPageUrl($page);
     }
     if (Mage::helper('mstcore')->isModuleInstalled('Mirasvit_SeoFilter') && Mage::registry('current_category') && Mage::helper('seo')->getFullActionCode() != 'review_product_list' && Mage::helper('seo')->getFullActionCode() != 'tag_product_list') {
         if (Mage::getModel('seofilter/config')->isEnabled()) {
             if ($page == 1) {
                 $url = Mage::getModel('seofilter/catalog_layer_filter_item')->getSpeakingFilterUrl(FALSE, TRUE, array());
                 return $url;
             } else {
                 $url = Mage::getModel('seofilter/catalog_layer_filter_item')->getSpeakingFilterUrl(FALSE, TRUE, array($this->getPageVarName() => $page));
                 return $url;
             }
         }
     }
     if (Mage::helper('seo')->getFullActionCode() == 'review_product_list' || Mage::helper('seo')->getFullActionCode() == 'tag_product_list') {
         return $this->getSeoReviewUrl($page, false);
     } else {
         if ($page == 1) {
             $params = Mage::app()->getFrontController()->getRequest()->getQuery();
             unset($params['p']);
             $urlParams['_use_rewrite'] = true;
             $urlParams['_escape'] = true;
             $urlParams['_query'] = $params;
             return $this->getUrl('*/*/*', $urlParams);
         } else {
             return $this->getPagerUrl(array($this->getPageVarName() => $page));
         }
     }
 }
Example #2
0
 public function getPageUrlParams($page)
 {
     $url = parent::getPageUrl($page);
     $clean_url = $url;
     if (strpos($url, "?") !== false) {
         $clean_url = substr($url, 0, strpos($url, '?'));
     }
     return str_replace($clean_url, "", $url);
 }
 public function getPageUrl($page)
 {
     return str_replace('?', '#%21', parent::getPageUrl($page));
 }