Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- /**
- * An extension for pagination class.
- *
- * @author Petra Barus <[email protected]>
- */
- class MPagination extends CPagination {
- /**
- * Creates the URL suitable for pagination. This method is overriden to add
- * a new functionality so that createURL could show page param = 1 for the
- * first page links.
- */
- public function createPageUrl($controller, $page) {
- $params = $this->params === null ? $_GET : $this->params;
- $params[$this->pageVar] = $page + 1;
- return $controller->createUrl($this->route, $params);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement