admin管理员组

文章数量:1332889

I need to have the ability to hide the Polylang metabox from the post edit page programmatically. I only want to show it to a few users, but hide it to people who do not have enough privileges.

There should be a possibility to do it programmatically with the wp javascript object like that

wp.data.dispatch('core/edit-post').removeEditorPanel('polylang-metabox-id');

I use this method for other boxes but I cannot find the ID of the Polylang box.

Any help would be appreciated.

本文标签: block editorHide Polylang metabox from the post edit sidebar