- Use
$role->add_cap()
to give a cap to a role, or useadd_role()
to create a new role with capabilities (ex:delete_specific_page
). - Use the
map_meta_cap
filter to update the$caps
array passed with the custom capability if the user is allowed to do the requested action. - Access can be revoked by using the
do_not_allow
capabilitiy.
Last active
July 14, 2016 23:21
-
-
Save petenelson/4244af7d2bcf752f3a4802aca1f88425 to your computer and use it in GitHub Desktop.
WordPress: notes on custom capabilities
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment