Subpages Navigation

Enabling the Subpages Navigation plugin will create a widget called Subpages Navigation which can be used to easily display a collapsible list of subpages anywhere on your site using one of the following ways:

  • As a sidebar widget
  • Using the 
    [subpages] 
    shortcode in a page

You can also create a custom menu and assign that menu to a page using this widget.

Activating the plugin(Figure 1) – to activate the Subpages Navigation plugin, please submit a ticket in the UBC Self Service Portal.

Figure 1: Activate the plugin

Figure 1: Activate the plugin

Adding the navigation using the widget.

To add the navigation using the widget, go to Dashboard > Appearance > Widgets > Subpages Navigation

Figure 2: Subpages Navigation Widget

Figure 2: Subpages Navigation Widget

 

Drag and drop the widget to a widget area.

The widget has options(Figure 2) like;

Figure 2: Subpages navigation Widget Options

Figure 2: Subpages navigation Widget Options

1. Widget Title – A title for the Widget(Optional). Check the Use title of root page checkbox to use the name of the root page as the widget title.

2. The drop-down next to the label Show lets you choose what kind of navigation to display.

  • subpages of the current page and its siblings
  • all pages
  • subpage of the top-level page

3. You may check the Nest children pages under their parents? option to nest the child pages under the parent page. Click Save and the widget should now appear on the widget area you selected.

Note:  If you have custom menu created under Appearance > Menus, then those menus will also appear in the dropdown list under Show(Figure 3)

Figure 3: Custom Menu on Subpages Navigation Widget

Figure 3: Custom Menu on Subpages Navigation Widget

 

Adding the navigation using shortcodes

Here is the syntax for the shortcode:

[ subpages menu=”Valuing Difference” ]

Note: “Valuing Difference” is the name of the sample custom menu.

The subpages shortcode has many more attributes.

'siblings' => 'false',
'collapsible' => 'true',
'exclusive' => 'false',
'expand' => 'false',
'menu' => ''

By default, subpages navigation will display child page of current page.

[subpages]

To display other pages on the same level of the current page, add siblings

[subpages siblings=true]
By default, child and grandchild of is collapse under the parent level. To disable collapsible and display navigation in a flat level.
[subpages collapsible=false]
To auto expand to current page, add expand
[subpages expand=true]
By default, subpages navigation allows user to open every single parent group. By adding “exclusive” parameter, it will limit the user to expand one parent level at a time and automatically collapse other opened levels.
[subpages exclusive=true]
To use custom menu
[subpages menu="menu-name"]

 

See Also