Menus can also be customised at space level using similar techniques...
Menus are constructed using unordered lists of links - as such, you can create a list of links on a page then embed the links within your menus by using the include macro or import macro (see 1 - Space Level Panel Content for more details).
For example, let's say you have some menu notation on a page called "Space Menu" in your wiki:
Because we're using the context-sensitive compound-menuitem macro, we will need to "import" (rather than "include") the notation in to the menu bar.
In the menu panel, use syntax like the following:
If the "Space Menu" page exists, it'll be imported directly in to your menu.
If you're not sure whether the list of links will contain valid markup, you should wrap the imported content in the wikimenu macro:
The wikimenu macro sanitizes it's content, for example removing unwanted line spaces, invalid markup, etc.
For example, if we wanted our Space Menu from the example above to only appear on the home page, we could use:
page parameter checks to see if the page exists and the
title parameter checks to see if the current page is called "Home". The menu will only be shown if both conditions are met.