Menu
  • HOME
  • TAGS

When creating a nav in SilverStripe, what is the number after $Menu?

navigation,silverstripe,template-variables

From the docs <% loop $Menu(1) %> Begins a loop through all the menu items, repeating all the HTML that is in the loop for each one. By passing (1) as an argument, we are asking the CMS to give us all the pages at level 1 of the hierarchy....

Linker error with variable templates

c++,templates,linker,c++14,template-variables

This is a bug in clang++ #22825. The bug report has been filed on 2015-03-06 and the bug has not yet been fixed. Richard Smith supposes this definition is incorrectly treated only as a forward-declaration.

Is it possible to get Children of children in a SilverStripe menu?

navigation,silverstripe,template-variables

Yes it is possible to loop through the Children of a Children loop. Your code looks correct to me. It should work correctly. Here are a few possible issues to check. Make sure all the pages at each level have ShowInMenus set to true. $Children and $Menu(1) only returns pages...