WPSAL (Simple Access List)

外掛說明

WPSAL (Simple Access List) is a lightweight plugin that allows WordPress site owners to control access to posts, pages and custom post types. You can restrict content to specific users or roles and redirect unauthorized visitors to any page.

Key Features

  • Restrict access to posts, pages or custom post types.
  • Assign access to individual users or roles.
  • Redirect unauthorized visitors to a page of your choice.
  • Developer-friendly with filters and hooks.

Usage

  1. Go to the Posts, Pages, or any custom post type list in the WordPress admin.
  2. Hover over a post row to reveal the WPSAL action menu. Click it.
  3. In the modal that appears, select the allowed users and/or roles.
  4. Optionally select a redirect page for unauthorized visitors.
  5. Click Save — the access restrictions are applied immediately.

Ideal for: membership sites, client portals, private blogs, or any scenario requiring flexible content access control.

Development Notes

This plugin includes minified JavaScript and CSS files.
The uncompressed source files are publicly available here:

  • SweetAlert2 v11.26.24: https://github.com/sweetalert2/sweetalert2/archive/refs/tags/v11.26.24.zip
  • TomSelect v2.6.0: https://github.com/orchidjs/tom-select/archive/refs/tags/v2.5.2.zip

Support / Documentation

  • For documentation, visit: https://wpsal.verya.xyz/.
  • For support or to report bugs, please visit the plugin page on the WordPress repository.

螢幕擷圖

  • Page List (Backend)WordPress admin page list showing all pages.
  • WPSAL Modal Window – Popup for selecting access type and individual settings.
  • WPSAL Settings Page – Main plugin settings page for configuring access control.

安裝方式

  1. Upload the wpsal-simple-access-list folder to /wp-content/plugins/.
  2. Activate the plugin through the ‘Plugins’ menu in WordPress.

常見問題集

Can I restrict custom post types?

Yes! By default, posts and pages are supported.
Use the wpsal_allowed_post_types filter to extend to custom post types.

Can I redirect unauthorized users?

Yes, you can select a custom page to redirect visitors who don’t have access.

Can I restrict access to both roles and users?

Absolutely. You can assign access to specific users, roles, or both simultaneously.

Is the plugin developer-friendly?

Yes, it provides filters and hooks for extending functionality and integrating with other plugins or themes.

Can I hide pages that are protected if they have WPSAL rules applied?

Yes! When the “Filter menus and navigation blocks” option is enabled in the plugin settings, the plugin automatically removes menu items and navigation block links that the current user cannot access.

使用者評論

這個外掛目前沒有任何使用者評論。

參與者及開發者

以下人員參與了開源軟體〈WPSAL (Simple Access List)〉的開發相關工作。

參與者

將〈WPSAL (Simple Access List)〉外掛本地化為台灣繁體中文版

對開發相關資訊感興趣?

任何人均可瀏覽程式碼、查看 SVN 存放庫,或透過 RSS 訂閱開發記錄

變更記錄

1.2.2

  • Updated SweetAlert2 and TomSelect libraries.

1.2.1

  • Updated SweetAlert2 and TomSelect libraries.

1.2.0

  • New feature: Added front-end filtering of menus and core/navigation blocks based on WPSAL access rules.
  • Cached access checks for performance improvements.
  • Updated SweetAlert2 and TomSelect libraries.

1.1.0

  • New filter: wpsal_permissions_column_post_types.
  • New feature: Remove all plugin metadata (reset permissions).
  • Improved, updated and standardized CSS selectors for better admin page compatibility.
  • Refined GUI: improved layout and visual overall clarity.
  • Improved performance by optimizing various meta queries.
  • Updated SweetAlert2 and TomSelect libraries.

1.0.0

  • Initial release:
    • User and role-based access control.
    • Redirect unauthorized users.
    • Modal interface with SweetAlert2 and TomSelect.
    • Developer hooks and filters.