Forum Replies Created
-
AuthorPosts
-
Vladimir
KeymasterIs it possible to look at your site with admin privileges? If ‘Yes’, send login credentials to support [at-sign] role-editor.com
URE Pro is built on the top of a free version (uses free version as the core) and includes full free version copy. So there is no need to activate free and Pro versions together. Every version has built-in control and checks if other copy of URE is running already before its activation.
Vladimir
Keymasters2member roles are usually used for membership and granted as the secondary roles. Right?
Restrict admin menu for the primary role of this user or grant ‘read’ capability to this s2member role.Vladimir
KeymasterThanks for the good feedback.
When you block admin menu item via “Admin menu access” add-on, URE blocks direct access to the URL linked to that menu item automatically. When user tries to type such URL in a browser URE redirects him to the 1st available admin menu item.
Vladimir
KeymasterHi,
You can block ‘Profile’ menu item for this role using “Admin menu access” add-on.
Vladimir
KeymasterHi,
Permissions assigned directly to users are not exported/imported by User Role Editor.
If it’s a single user it’s much simpler just grant capabilities shown at a production site page to at this user permissions page opened at the stage server.If you wish to make it semi-automatically, you will need some SQL tool. Look at this command:
SELECT * FROM wp_usermeta where user_id=NNN and meta_key='wp_capability';It shows user permissions stored by WordPress for this user at the database.
NNN – is your user ID.
‘wp_’ is database prefix here. So you have to change it at ‘wp_usermeta’ table name and at ‘wp_capability’ value if you have another DB prefix defined at config.php.Then you can to copy/paste meta_value field value from the result to the previous command to a new command at the stage database connection:
update wp_usermeta set meta_value='copy/pasted value here' where user_id=NNN;Vladimir
KeymasterI see your role has all capabilities from ‘posts’ and ‘pages’ groups. It’s enough to edit any post or page, in general. You need to check if your role or/and user does not have any additional restriction, may be set accidentally or by other plugin.
1) try to deactivate User Role Editor and re-test;
2) try to deactivate all plugins and re-test.
In case if restriction was added by some plugin, activate plugins back one by one and make another test in order to isolate a reason.Vladimir
KeymasterTry development version 4.47.b1. It’s available after login from the Download page. It includes the fix for this issue.
Vladimir
KeymasterRevoke ‘delete_posts’, ‘delete_publish_posts’ capabilities from this role.
Vladimir
KeymasterIt’s better to use current_user_can() for checking if capability was granted to a user or it was not. To check if user has role it’s more correct to use this code:
$user = wp_get_current_user(); if (in_array('some_role_id', $user->roles)) { // do something }Vladimir
KeymasterHi,
You should not call current_user_can() directly from mu-plugin code. You have to enclose it into some function hooked to the action when WordPress will load it’s core code already, like this:
add_action('admin_init', 'load_mu_plugin'); function load_mu_plugin() { if ( current_user_can('page-editor') ) { add_filter('page_row_actions','remove_quick_edit',10,1); add_filter('post_row_actions','remove_quick_edit',10,1); } }Vladimir
KeymasterI got it. Thanks. I will work on a solution.
Vladimir
KeymasterYou are right. Divi theme does not register its custom post types for users.php page, so URE does not see/show them. It seems Divi code changed and related part of URE became incompatible.
What version of Divi do you use?
I have on hands v. 3.0.101? Is it possible to get from you a recent one for testing/investigation?Vladimir
KeymasterHi,
If you write about categories selection meta box inside post editor page it’s possible to hide it from a role via “Meta boxes access” add-on. If you write about other element, show a screenshot, what do you wish to hide.
Vladimir
KeymasterStatic page selected as a “Home page” is available for editing by default to any user with edit_pages, edit_others_pages, edit_published_pages capabilities.
Did you set any additional edit restrictions for this role or user with this role?16/05/2018 at 03:28 in reply to: Invalid Argument warning when editing capabilities for a specific user. #4848Vladimir
KeymasterThank you for this information. This bug is fixed in version 4.46. It was published today.
-
AuthorPosts