[WordPress] 外掛分享: Restrict Block Content

首頁外掛目錄 › Restrict Block Content
WordPress 外掛 Restrict Block Content 的封面圖片
全新外掛
安裝啟用
尚無評分
294 天前
最後更新
問題解決
WordPress 6.7+ PHP 7.4+ v1.0.1 上架:2025-05-18

內容簡介

**總結:**
這個WordPress外掛預設允許您在區塊編輯器和完整網站編輯器中對核心/組和核心/行區塊添加限制。 限制包括為該區塊啟用限制,設置RCP所使用的存取級別,並確定使用者在區塊編輯器中必須至少具有該存取級別,或者不能具有該存取級別。

**問題與答案:**
1. 這個WordPress外掛的功能是什麼?
這個外掛允許您在區塊和完整網站編輯器中對核心/組和核心/行區塊添加限制。

2. 在限制功能中包括哪些步驟?
- 啟用該區塊的限制
- 設置RCP所使用的存取級別
- 確定使用者在區塊編輯器中必須至少具有該存取級別,或者不能具有該存取級別

3. 這個外掛的完整原始碼在哪裡可以找到?
可以在GitHub這個連結找到外掛的完整原始碼:[https://github.com/bethinkstudio/restrict-block-content](https://github.com/bethinkstudio/restrict-block-content)

外掛標籤

開發者團隊

⬇ 下載最新版 (v1.0.1) 或搜尋安裝

① 下載 ZIP → 後台「外掛 › 安裝外掛 › 上傳外掛」
② 後台搜尋「Restrict Block Content」→ 直接安裝(推薦)
📦 歷史版本下載

原文外掛簡介

This plugin will allow you, by default, to add restrictions to core/group and core/row blocks in the block and full-site editors.
Restrictions involve enabling it for that block, then setting the access level used by RC/RCP, and then determine whether the user must have at least that access level, or not have that access level in the block editor.
For details about how Access Levels work, here is a resource from the creators: https://help.solidwp.com/hc/en-us/articles/360049322274-How-do-access-levels-work
This plugin relies on either Restrict Content available on the WordPress.org Plugins Repository, or the premium version of Restrict Content Pro.
Note: If you are using Restrict Content Pro, and facing an issue where this plugin’s dependencies do not seem to be met, make sure you are using RCP ≥ 4.5.46, which supports plugin dependencies for the free version as well through the wp_plugin_dependencies_slug filter.
If you need to use this with an older version, you can apply this filter manually:
/**
* Filter so that plugins listing the free version as a dependency would also be satisfied by the Pro version.
*
* @param string $slug The plugin slug being checked.
*/
add_filter( 'wp_plugin_dependencies_slug', function( $s ) {
if ( 'restrict-content' === $s ) {
$s = 'restrict-content-pro';
}
return $s;
});

Source Code
Full source code is available on Github here:
https://github.com/bethinkstudio/restrict-block-content

延伸相關外掛

文章
Filter
Apply Filters
Mastodon