public function createLinks() { $pager = $this->_getPager(); $numPages = count($pager->getPages());
! //Need this to add the links to later on $headBlock = Mage::app()->getLayout()->getBlock(‘head’);
//Determine exactly what needs to be output and //add to the head block if (!$pager->isFirstPage() && !$pager->isLastPage() && $numPage $headBlock->addLinkRel(‘prev’, $pager->getPreviousPageUrl() $headBlock->addLinkRel(‘next’, $pager->getNextPageUrl()); } elseif($pager->isFirstPage() && $numPages > 1) { $headBlock->addLinkRel(‘next’, $pager->getNextPageUrl()); } elseif($pager->isLastPage() && $numPages > 1) { $headBlock->addLinkRel(‘prev’, $pager->getPreviousPageUrl() }
https:/ /github.com/drewhunter/SeoPagination return $this; }
hans2103
22 May 2014