1. Create a Menu Item
Click the “New menu” toolbar button:
The plugin will insert the new item below the currently selected item.
2. Choose the Target Page
The “Target page” setting determines what will happen when the user clicks the menu. In the free version, there are three main options:
Link to an Existing Admin Page
This essentially makes the menu a copy of another menu item.
You can have as many copies as you want, but watch out for permission conflicts and duplicate URLs at the top level. When two menus have the same target page but different capability settings, you can end up in a situation where both items become inaccessible. If that happens, try either explicitly setting the same capability for both or using the “hide without preventing access” button.
Link to a Custom URL
Choose the < Custom URL >
option from the target page drop-down and enter a valid URL in the “URL” field. You can use fully qualified URLs or relative URLs. Here are a few examples:
http://example.com/page.html
https://example.org/abc/?parameter=value#anchor
/wp-admin/options-general.php?page=menu_editor&sub_section=plugin-visibility
– a relative URL that points to the “Plugins” tab of the menu editor.
By default, clicking the menu item will open the specified URL in the current tab. If you want to make it open in a new tab or an <iframe>
, you’ll need the Pro version of the plugin.
Make an Non-Clickable Menu (“None”)
Choose the < None >
option to create a menu item that doesn’t link to anything. This is intended as a way to help organise large menus. A non-clickable item can be used as a label, a separator or a section heading.
3. Set Permissions
Overall, permissions for custom menus work the same way they do for built-in menus and plugin menus: you can configure them by changing the “extra capability” setting. However, there are a couple of things to keep in mind:
- There’s no fixed “required capability”. If necessary, you can allow any role to see the menu item, even Subscriber.
- When you create a new menu and use the “Custom URL” option to link to an admin page, any access restrictions that apply to that page will also apply the new menu. For example, lets say you set the URL to
/wp-admin/options-general.php
(i.e. Settings -> General) and you set the extra capability to “read”. All built-in roles have this capability. Authors and editors will be able to see this menu, but if they try to click it, they’ll get a “permission denied” error. This is becauseoptions-general.php
checks if the user has the “manage_options” capability.
4. Adjust Other Settings
- Replace the automatically generated title.
- Change the icon.
- Change the window title.
- etc.
Notes
- To delete a menu item, click this button:
- It’s not possible to delete built-in menus or menus created by other plugins. If you need to get rid of them, try hiding them instead.
- Each top level menu must have a unique URL. If you need two items to link to the same page, try adding a random query parameter to both URLs to make them unique. For example, instead of two links to
https://example.com/
, usehttps://example.com/?abcd=987654
andhttps://example.com/?abcd=123456
.