To hide child pages of a parent:
- In the Dashboard, go to "View Full Dashboard"
- Pages & Themes > Attributes
- Scroll all the way down to "Add Attribute"
- From the dropdown, select checkbox and click "Add"
- In Handle, enter the following: exclude_subpages_from_nav
- In Name, enter the following: Exclude Subpages from Nav
- Click "Add"
- Now go to "Page Properties" of the parent page
- Click the "Custom Attributes" tab
- In the left column, find the new attribute "Exclude Subpages from Nav" that you just added and click on it so it gets crossed out
- Now scroll back up and check the "Exclude Subpages from Nav" box under the "Selected Attributes" section
- Click "Save"
- Now check your autonav, the parent page should appear, but child pages should be hidden.
If you find that this method is not working, make sure that you're using a recent version of view.php in your custom autonav template, because that's where the autonav checks for hidden subpages.
- You can always grab the latest view.php file at concrete/blocks/autonav/view.php
- Copy it from there and paste it into your custom autonav template, for example SITEROOT/blocks/autonav/templates/dropdown_menu/view.php
Hope this helps somebody!
Loading Conversation