-
Improvement
-
Resolution: Fixed
-
Trivial
-
3.1.0-dev
-
None
Since phpBB 2 pagination has been rendered mostly within the source. This limits just what designers can do with pagination. The current form is also questionable in terms of "best practice". The aim is to move rendering completely to the template via the use of a block element. Enabling S_ template vars also allows for control over specific aspects of the pagination output such as next, previous, active and ellipsis.
Related to this - merging the capabilities of the topic_generate_pagination with generate_pagination removes an element of duplication.
Templates can utilise the new functionality as such:
<div class="pagination">
|
<ul>
|
<!-- BEGIN pagination -->
|
<!-- IF pagination.S_IS_PREV -->
|
<!-- ELSEIF pagination.S_IS_CURRENT -->
|
<li class="active"><span>{pagination.PAGE_NUMBER}</span></li>
|
<!-- ELSEIF pagination.S_IS_ELLIPSIS -->
|
<li class="ellipsis"><span>{L_ELLIPSIS}</span></li>
|
<!-- ELSEIF pagination.S_IS_NEXT -->
|
<!-- ELSE -->
|
<li><a href="{pagination.PAGE_URL}">{pagination.PAGE_NUMBER}</a></li>
|
<!-- ENDIF -->
|
<!-- END pagination -->
|
</ul>
|
</div>
|
Embedding pagination blocks within other blocks is done in a similar way, extending the block names in the variables as required.
- caused
-
PHPBB-11014 Previous/next links are no longer displayed.
- Closed
-
PHPBB-11067 Pagination in ACP is missing CSS code from pagination change
- Closed
-
PHPBB-11018 Pagination in memberlist
- Closed
-
PHPBB-11047 Unclosed variable shows incorrect language key
- Closed
-
PHPBB-11065 li tag on topic display options at MCP is unclosed
- Closed
-
PHPBB-11796 Duplicate code for pagination
- Closed
-
PHPBB-11023 Fix excess tabbing and spacing in functions.php
- Closed