Open phideas opened 7 years ago
This can also be added with the following in the partial templates: {% include 'partials/archives.html.twig' with {base_url:base_url ~ page.url} %}
This adds the link to route to the same page (blog) that you are on.
As a short remark, if you're using multiple languages, you need to use another variable, because both base_url
and page.url
contain the language code. With base_url:base_url ~ page.url
, you'll end up with something like https://your-site.tld/en/en/blog/archives_month:aug_2019
, which will lead to a 404 error. The theme variable base_url_simple
contains the base url without the language code. So you can just use base_url:base_url_simple ~ page.url
.
I did setup 2 separate blogs on site using 2 blog_list pages. Archive plugin missing the blog_list page route in links to archived pages. I solved this with a quick hack. Please check it out.
Added new variable "route" in user/plugins/archives/archives.php
Added "route" in user/plugins/archives/templates/partials/archives.html.twig