Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixing the bug where tags and author filters didn't persist through p…
…agination.
- Loading branch information
1 parent
d5bdb9f
commit df12bb0
Showing
3 changed files
with
27 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,29 +1,22 @@ | ||
<?php $params = unescape_variable($params) ?> | ||
<?php $webRoot = sfConfig::get('app_io_blog_web_dir', '/ioBlogPlugin') ?> | ||
|
||
<?php if ($pager->haveToPaginate()): ?> | ||
<div class="pagination"> | ||
<a href="<?php echo url_for('io_blog_index', array('page' => 1)) ?>"> | ||
<?php echo image_tag($webRoot.'/images/pager/first.png', array('alt' => 'First page')) ?> | ||
</a> | ||
<a href="<?php echo url_for($route, array_merge($params, array('page' => 1))) ?>"><?php echo image_tag($webRoot.'/images/pager/first.png', array('alt' => 'First page')) ?></a> | ||
|
||
<a href="<?php echo url_for('io_blog_index', array('page' => $pager->getPreviousPage())) ?>"> | ||
<?php echo image_tag($webRoot.'/images/pager/previous.png', array('alt' => 'Previous page')) ?> | ||
</a> | ||
<a href="<?php echo url_for($route, array_merge($params, array('page' => $pager->getPreviousPage()))) ?>"><?php echo image_tag($webRoot.'/images/pager/previous.png', array('alt' => 'Previous page')) ?></a> | ||
|
||
<?php foreach ($pager->getLinks() as $page): ?> | ||
<?php if ($page == $pager->getPage()): ?> | ||
<b><?php echo $page ?></b> | ||
<?php else: ?> | ||
<a href="<?php echo url_for('io_blog_index', array('page' => $page)) ?>"><?php echo $page ?></a> | ||
<a href="<?php echo url_for($route, array_merge($params, array('page' => $page))) ?>"><?php echo $page ?></a> | ||
<?php endif; ?> | ||
<?php endforeach; ?> | ||
|
||
<a href="<?php echo url_for('io_blog_index', array('page' => $pager->getNextPage())) ?>"> | ||
<?php echo image_tag($webRoot.'/images/pager/next.png', array('alt' => 'Next page')) ?> | ||
</a> | ||
<a href="<?php echo url_for($route, array_merge($params, array('page' => $pager->getNextPage()))) ?>"><?php echo image_tag($webRoot.'/images/pager/next.png', array('alt' => 'Next page')) ?></a> | ||
|
||
<a href="<?php echo url_for('io_blog_index', array('page' => $pager->getLastPage())) ?>"> | ||
<?php echo image_tag($webRoot.'/images/pager/last.png', array('alt' => 'Last page')) ?> | ||
</a> | ||
<a href="<?php echo url_for($route, array_merge($filterQueryParams, array('page' => $pager->getLastPage()))) ?>"><?php echo image_tag($webRoot.'/images/pager/last.png', array('alt' => 'Last page')) ?></a> | ||
</div> | ||
<?php endif; ?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters