Hi
This is my first try with Grav and the whole flat file system concept and the general software seems great.
However, I can’t seem to find the answers in the documentation. MY main question is:
I have dropped a page (in this example called ‘Portfolio’) and yet I still get a link for it in the Navbar.
I see this code in the navigation
{% for link in site.links %}
{% if link.url | contains(‘http’) %}
{% set domain = ‘’ %}
{% elseif link.url | contains(’#’) %}
{% set domain = ‘’ %}
{% else %}
{% set domain = base_url_absolute %}
{% endif %}
{% endif %}
Can you tell me where the site array (I assume) is populated and therefore the links??
I have looked at every page including the Frontmatter but can find no mention of this deleted page so how is it still in the navigation?
Any help most appreciated.
So this is configured in the site.yaml in the config directory.
Is there no way to change this in the admin plugin? Seems a little disjointed that you can create/edit/delete pages in the admin plugin but cannot change the navigation links.
The theme/skeleton you are using must be building the menu from site configuration. This is not the standard approach. Usually the menu is built from the actual page structure by iterating over the Pages object. The thing about Grav is that there is no one-way and the theme itself, has a large part in handling how things are displayed.
Thank you for that. It didn’t sound like a good approach to me. I assumed that everything would be built dynamically but its good to now its the theme and not the app. I appreciate you responding. It would be easier if you could at least edit these files from within the admin panel but now I know. Many thanks.