robbyahn/silverstripe-menumanager-subsites

This package is not installable via Composer 1.x, please make sure you upgrade to Composer 2+. Read more about our Composer 1.x deprecation policy.

Installs: 196

Dependents: 0

Suggesters: 0

Security: 0

Stars: 0

Watchers: 1

Forks: 6

Type:silverstripe-module

1.1.2 2018-10-02 18:11 UTC

This package is not auto-updated.

Last update: 2021-11-25 08:29:21 UTC


README

This module enables per subsite menu sets using Heyday's Menu Manager module.

Installation

Install via composer:

composer require guttmann/silverstripe-menumanager-subsites dev-master

No other configuration is required. Once installed any menu sets created will be linked to the currently selected Subsite at the time of creation.

Usage

Menu sets can still be accessed from templates via $MenuSet("Your Menu Set").MenuItems but if you want to ensure each Subsite only accesses its own MenuSets you can use this in your templates instead:

<% loop $SubsiteMenuSet("Your Menu Set").MenuItems %>
    <a href="$Link" class="$LinkingMode">$MenuTitle</a>
<% end_loop %>