Showing content from another page when I click on a parent link

Hi Guys;
Let’s say I have this page structure:

I want to have the parent menu name appear on the nav, but when I click on it the default content comes from the Child 1. This is my menu structure:

First level >  Parent 1 > Parent 2 > Parent 3 > Parent 4
Second level  > Child 1 > Child 2 > Child 3 > Child 4 (all of second level belong to Parent 3)
third level > Grandchild 1 > Grandchild 2 (These could be 2, 3 or 4, depends on the content of the Child)

Now, if I click on Parent 3, I will see all of my second level menu, but then, if I click on the, let’s say, Child 2, the third menu for that child would show BUT the content of the first grandchild would show, Child 2 itseld does not have content, but I need it on the menu so that I can create a visual cue of the selections.

How do I automatically display the content of Grandchild 1 when I click on Child 2 without having an empty page show first and then I having to select the Grandchild 1.

Not sure if it’s clear :slight_smile:
Thanks!

I am a little confused here, are you talking about menu behaviour or having content form one page into another?

  1. For the menu: That will depends on how your template handles the menu in twig.
    See this site I am using Helium theme, I have the Services & Techniques menu item as routable: false in page header. In that way the theme does not render a link for that menu item, just behavies like a drop down on hover, showing child items links.

  2. If you are talking about showing content form other pages, you could create a new twig template to show child pages content, or you could use the page-inject plugin.

2 Likes

shoot!..I’m gonna need both of your suggestions!
awesome!..thanks @hugoaf!