Hello guys,
I have a problem to paginate between the previous and following pages of articles. This is due to the changes I made in the content items of the blog. Indeed, I replaced (@ self.children) by @ self.modular: / home in item.fr.md then I added:
{% set options = { items: {’@self.children’:’’}, ‘limit’: page.header.bloglimit, ‘order’: {‘by’: ‘date’, ‘dir’: ‘desc’}, ‘pagination’: true } %}
{% set collectionblog = page.collection(options) %}
in blog-item.html.twig with :
{% if not page.isLast %}
<a class="btn" href="{{ page.prevSibling.url }}"><i class="fa fa-angle-left"></i> {{ 'Precedent'|t }}</a>
{% endif %}
{% if not page.isFirst %}
<a class="btn" href="{{ page.nextSibling.url }}">{{ 'Suivant'|t }} <i class="fa fa-angle-right"></i></a>
{% endif %}
the next and previous buttons block on the same page.
I really need your help please.
images :
THEME: Big Picture