WP Manifestindependent plugin directory
manifest / content / restricted-authors

AuthorFence

Restrict which categories each author can publish in, with per-author and per-role default category support.

by Chris Kelley · github.com/iwritec0de/restricted-authors · website

0stars
0forks

Install

No release zip yet. The repository archive installs, but the folder name will carry the branch suffix and updates will not flow:

wp plugin install https://github.com/iwritec0de/restricted-authors/archive/refs/heads/main.zip

Readme

AuthorFence

Restrict which categories each author can publish in — per role, per user, with smart default-category resolution.

AuthorFence is a WordPress plugin for editorial teams that need to keep specific authors (or entire roles) inside a defined set of categories. It works in both the classic and block editors, handles multi-role users, and ships with a GitHub-based auto-updater.


Features

  • Per-role restrictions — dynamic, searchable picker on Settings → AuthorFence lets you add category restrictions for any role that has edit_posts.
  • Per-user overrides — individual authors can have a bespoke category list set from their profile screen.
  • Priority chain for the default categoryuser → role → global → WordPress default.
  • Multi-role resolution — most permissive role wins; any unrestricted role makes the user unrestricted.
  • Administrators are never restricted.
  • Block editor aware — the REST categories endpoint is filtered so restricted users only see the categories they can publish in.
  • Self-updating — bundled GitHub Releases updater checks iwritec0de/authorfence for new tagged releases.
  • Clean uninstalluninstall.php removes all options, transients, and per-user meta.

Requirements

  • WordPress 6.5+
  • PHP 8.0+

Installation

  1. Download the latest release zip from the Releases page, or clone this repo and run the build.
  2. Upload via Plugins → Add New → Upload Plugin and activate, or drop the folder into wp-content/plugins/.
  3. Configure role restrictions under Settings → AuthorFence. Per-user overrides live on each user's profile screen.

Resolving Allowed Categories

AuthorFence::get_allowed_categories_for_user( \WP_User $user ): ?array

  1. Administrators → null (unrestricted).
  2. Per-user override → explicit term IDs.
  3. Role-based restrictions → most permissive role wins. Any unrestricted configured role → null.
  4. Otherwise → null.

License

GPL-2.0-or-later. See LICENSE.

Read the full README on GitHub →