Can I stop my client from adding terms to a certain taxonomy? So that I set up a fixed amount of terms, and that´s what they get to choose from.
Can I remove the menu item for certain taxonomies in the backend? Let´s say I have created two taxonomies, and I want the user to be able to access one of them and the other should be hidden and only show up as options in the editing of posts/pages.
When you registered the taxonomy with
register_taxonomy
there is acapabilities
argument. This takes, an array of the capabilities for this taxonomy. In particular:Associated with each of them should be a capability that it is required to be able to perform that action. For instance to
assign_terms
usually requires the user to have the capabiliy ofedit_posts
. You can give the first three some capability (custom or otherwise,manage_options
might do) that your clients do not have, but you do. The last can be justedit_posts
.As an example: