Blog Sections Open
Changing Wayfinder startId Based on the Current Section with if
A practical Wayfinder trick for choosing different start points depending on the current page or parent section.
One menu tree does not always fit every section. the underlying example used the if snippet to switch Wayfinder’s startId dynamically depending on whether the current page belonged to a special section or should fall back to the parent branch.
Example idea
[!Wayfinder?
&rowTpl=`rowTplZ`
[[if?
&is=`[*id*]:in:6`
&then=`&startId=[*id*]`
&else=`&startId=[*parent*]`
]]
!]
Why this helps
- You can keep one menu definition while adapting it to local context.
- Special landing sections can become their own menu roots.
- Ordinary pages can still inherit the expected parent-based navigation.
This is a good example of using small conditional logic to keep navigation flexible without duplicating whole menu snippets.
Newer post
Filtering DocLister Results by a TV Value with containsOne
How to use DocLister containsOne TV filters as a cleaner alternative to older Ditto-style local filters.
Older post
Using AjaxSearch with Multi-Select TV Filters
How to combine AjaxSearch with multi-select TV data in Evolution CMS without losing predictable filtering behavior.