Forum Replies Created
-
AuthorPosts
-
VladimirKeymaster
Hi,
Just to check, will issue go away if you unblock access to the built-in ‘Posts’ menu item?
VladimirKeymasterDid you block some menu items for this role using “Admin menu”? If Yes and use ‘not selected’ blocking model, try to switch to ‘selected’ as a workaround or read carefully last part of the documentation article “Technical details” in relation to “Block not selected” variant.
VladimirKeymasterHi,
Is it possible to look at your site with administrator privileges? If ‘Yes’, send user/password and site URL to support [at-sign] role-editor.com
VladimirKeymasterYou can activate “Admin menu access” add-on:
https://www.role-editor.com/block-admin-menu-items
select ‘Administrator’ role at Users->User Role Editor and look, what capability is used by plugin to protect its menu item(s).VladimirKeymasterCan you save such changes as a user with custom role in case you switch Off “Admin menu access” checkbox in the URE Settings temporally?
If ‘Not’ problem may be not related to URE, but to JavaScript/AJAX error. Look for any error messages in the browser JavaScript console.
08/05/2020 at 11:32 in reply to: How can i asign or create one rol who can change from one member type to other #6823VladimirKeymasterIt’s possible to allow to a user with one role to edit only users of the selected role(s). Look at the “Other roles access” add-on. I think you can use it as a workaround for your task.
For example, use different roles: Role A, role B. Grant to role A list_users, edit_users and allow it access to the users with role B only…
VladimirKeymasterIf you use “Not Selected” model, pay attention of the final part “Technical Details” of the article:
VladimirKeymasterCustom code may help only. New user is registered via WordPress internal function wp_insert_user(). This function executes special action:
/** * Fires immediately after a new user is registered. * * @since 1.5.0 * * @param int $user_id User ID. */ do_action( 'user_register', $user_id );
Thus, it’s possible to hook own function to ‘user_register’ action and add secondary role to user according to his primary role.
08/05/2020 at 02:15 in reply to: How can i asign or create one rol who can change from one member type to other #6818VladimirKeymasterHi,
Are member types the user roles?
VladimirKeymasterHi Laurent,
Thanks for the information.
URE is not network activated at your WP multisite. Thus you have to work with URE settings separately for every site where you activated URE.
I went to the main site “Settings->User Role Editor->General” tab and found that “Show Administrator role at User Role Editor” checkbox is turn OFF as it is by default. URE hides ‘administrator’ role from the user in this case. I turned this checkbox ON and ‘administrator’ role is available for selection now at the main site. If you need the same at the subsite you have to make the same at the URE settings.Other way – network activate URE and make needed settings once at the Network Admin->Settings->User Role Editor.
VladimirKeymasterHi Laurent,
If it’s possible to look at your site with superadmin privileges, send URL and user/pwd credentials to support [at-sign] role-editor.com
VladimirKeymasterYes, WPForms (I tested WPForms Lite) uses ‘manage_options’ capability by default for all its menu items. Good news that WPF does not check ‘manage_options’ directly, but makes it via function wpforms_get_capability_manage_options(), which allows to replace ‘manage_options’ with any other capability using custom filter ‘wpforms_manage_cap’. Try to add own piece of code to the active theme functions.php file or setup it as a must-use plugin:
function replace_wpf_cap( $cap ) { return 'capability_of_your_choice'; }
You can add custom capability ‘wpf_edit_forms’, for example and use it in this filter.
I do not exclude that WPF Pro may use another permissions for its menu items and pages.VladimirKeymasterUser Content view restrictions add-on.
You need 1st to add restrictions for all pages which should not be viewable by not logged-in users – open page for editing and select for it at least “Any User Role (logged in only)” at the “Content view restrictions” section.
Then you can allow to the selected role to view the selected pages by ID list – via Users->User Role Editor. Or make it directly for the every page – selected at the page editor which roles can view this page.VladimirKeymasterHi Denish,
Yes, it should copy admin menu settings for the roles from the main site to a new created site. But you still need to configure this manually via active theme functions.php or must-use plugin. Use this code for that.
01/05/2020 at 10:36 in reply to: Pro version – multisite – shop manager can’t delete product attributes #6800VladimirKeymasterThanks for the provided access. I confirm a problem and can reproduce it at my test environment to make further investigations.
The reason is that post editing ‘edit.php?…’ link is blocked via ‘Admin menu’, but WooCommerce uses the same link with another set of parameters for the product attributes deletion. Somehow URE Pro counts the ‘edit.php?post_type=product&page=product_attributes&delete=4&_wpnonce=…’ link as blocked and redirects user to the dashboard instead. I have to investigate the issue to decide if it’s possible to find the solution for this conflict.Generally, ‘Admin menu’ is the secondary level permissions tool. 1st level is always capabilities. We should revoke all unneeded capabilities from the role 1st. I see that you fully blocked for shop_manager role via “Admin menu” the “Appearance”, “Users”, “Links” menus. If revoke “edit_theme_options”, ‘list_users’ and ‘manage_links’ capabilities from shop_manager role, then this menus will be blocked for the role by WordPress itself.
The same is correct for the ‘Pages’ menu. I revoked all ‘_pages’ capabilities from shop_manager role at the demo site and this menu was disappeared from the user access.
The same is true for all custom post types menus, currently protected by ‘edit_posts’ capability. If revoke, all ‘_posts’ capabilities from shop_manager role, then you will not need to block related menus via ‘Admin menu’. It resolves the issue, when shop manager can not delete product attributes also.
Possible problem with this workaround is the ‘edit_posts’, ‘edit_published_posts’, ‘edit_others_posts’, ‘delete_posts’ capabilities are required by default for editing Media Library items.
I will inform you about the result of my further investigations on the subject.
-
AuthorPosts