Contents
Roles and Permissions - Plugixa Permalink Manager
Out of the box the plugin is for administrators. This page is for sites where somebody else, such as an editor or an SEO consultant, should be able to use part of it.
The six capabilities
Access is decided by six ordinary WordPress capabilities. Each one opens one kind of action.
| Capability | Allows | Edition |
|---|---|---|
plugixa_permalink_manager_view |
Opening the screens and reading addresses, patterns, redirects and history | Free |
plugixa_permalink_manager_edit |
Changing addresses in the URI Editor | Free |
plugixa_permalink_manager_redirects |
Adding, changing and deleting redirects on the Redirects screen PRO | Pro |
plugixa_permalink_manager_tools |
Running Regenerate, the Health check and Find and replace, and undoing a run | Free |
plugixa_permalink_manager_import_export |
Seeing the import sources and running an import | Free |
plugixa_permalink_manager_manage_settings |
Changing settings, patterns and integration switches | Free |
All six exist in both editions. The redirects capability has nothing to act on until Pro adds the Redirects screen.
Who has them
Administrators hold all six, always. They are written onto the Administrator role when the plugin is activated, and anybody who may manage the site’s options is treated as holding them even if another plugin removes one.
Nobody else has any. The plugin has no screen for handing them out. Because they are standard WordPress capabilities, any role editor plugin can add them to a role or to a single user.
Two rules when you grant them
Always include view. Every screen reads data, and reading needs view. A
role given only tools, for example, sees the menu and is then refused by every
screen behind it.
Never grant plugixa_permalink_manager_manage. You may notice a seventh
name in a role editor. It only means “may open the plugin’s menu”, and WordPress
works it out by itself for anybody who holds one of the six. It is not meant to
be ticked: on its own it shows the menu while every request is still declined.
Typical combinations
The names below are shortened: view stands for
plugixa_permalink_manager_view, and so on.
| For | Grant |
|---|---|
| Somebody who should only look | view |
| An editor who fixes addresses | view, edit |
| An SEO consultant | view, edit, redirects, tools |
| Somebody moving the site from another permalink plugin | view, import_export |
Editing an address needs two things
The edit capability lets somebody use the URI Editor. It does not let them
change the address of content they could not otherwise edit. Every change is
also checked against WordPress’s own rules for that post or term, so an author
with edit can change the addresses of their own posts and not of somebody
else’s.
The edit screens are a separate choice
The Permalink box, the term fields and Quick Edit do not use the six capabilities. They follow one setting, Who may edit addresses on the edit screens, in Advanced settings. Authors and above can use them by default, on the content they are allowed to edit. See Edit screens and Quick Edit.
Actions that need more than the plugin’s own capability
| Action | Also needs |
|---|---|
| Changing Delete all permalink data when the plugin is deleted | The WordPress permission to manage options |
| Deactivating Permalink Manager from the conflict banner | The WordPress permission to activate and deactivate plugins |
| Seeing the notice that the database tables could not be created | The WordPress permission to activate plugins |
From code
plugixa_permalink_manager_user_can filters every permission decision, and
plugixa_permalink_manager_can_edit_object filters whether the current user may
change the address of one item. Both are listed in
Hooks. The permission each
REST route asks for is in
REST API.
Troubleshooting
| What you see | Why |
|---|---|
| The menu appears but every screen says you are not allowed | The role is missing view |
| No menu at all | The user holds none of the six |
| The URI Editor refuses one item and saves the others | The user cannot edit that post or term in WordPress |
| An author sees the Permalink box but not the plugin’s menu | That is the edit-screens setting at work; it is independent of the six |