I have created a website for my classes with Grav. So far it works perfect. I decided to use two different blogs on this website. This seems to cause a problem with Tags & Archives.
Tags are correctly shown in my sidebar (all Tags are shown on both blogs).
Archives are correctly shown in my sidebar (all Archive items are shown on both blogs).
Issue: If I click Tags or Archive items it will only show the ones provided in the blog I have opened at this very moment. The link won’t redirect to the other blog.
I tried to figure out what I have to do in the twig files to implement a redirect, but I don’t seem to do it right.
I guess this is considered quite a newbie problem, but I would be very grateful, if someone took few minutes and helped me out here.
Have you checked that you include all tags needed in both different blogs? Can you provide a screenshot of your current view on the page that includes both, and the one that misses some? Just to make this question a bit easier to understand, thanks!
The tags I use are both connected to the default ‘blog template’. I want to use the tags sidewide (to make it possible for students to click them from any page).
If I click one of the tags (which should be linked to a different blog on my site, the link will only show a blank page like this (In this case I clicked the #simplepresent tag, which is from a different blog in a different folder:
I have a similar setup, and you need to fiddle with the ‘Blog Route’ in Blog Config.
That determines the new_base_url used in the templates to search in the correct area.
To add to that: this only works well for the first page in /root (eg blog, blog2 in there). But when you add more pages in that blog2 directory, then the tag search is still in the first /blog.
Anyone knows if that is a bug, or am I doing something wrong here?
You can double check by using
{{ new_base_url|t }}
{{ blog.url|t }}