Forum Replies Created
-
AuthorPosts
-
Vladimir
KeymasterHi,
What redirection plugin to you use. Send download link here if it’s free. Or share its copy with support [at-sign] role-editor.com via DropBox or similar service in order I can test and investigate what permissions it requires.
Vladimir
KeymasterThanks. I got access to your site.
It seems that described issues with test user sjwtest were gone. Please confirm:
– I see “Log Out Everythere else” button at his user profile;
– I see “Posts/Pages/Custom Post Types Editor Restrictions” section configured to “Allow” to edit 4 pages and 4 posts categories.As about access to the media folders for restricted user. When you apply edit restrictions to a user, such restrictions are applied to the Media Library also. Restricted user sees at the Media Library his own items (images) only. If there are know images uploaded by this user, he will see the empty Media Library.
If you wish to allow to see full Media Library withou restrictions you can use custom filter ure_attachments_show_full_list. Let me know if that helped.Vladimir
KeymasterHi Maarten,
“Update Network” replicates all roles from the main site to all subsites of the network and fully overwrites existing subsites roles. Currently it’s not possible to replicate just part of the roles and do not remove roles which does not exist at the main site.
It’s a subject of a future development – may be next year.
Vladimir
KeymasterHi,
Thanks for letting me know that the issue was resolved.
Did you turn ON ‘Activate “Create” capability for posts/pages/custom post types’ option at URE Settings? Yes, in this case we have to grant ‘create_posts’, ‘create_pages’ capability to the roles, including ‘editor’ manually.
Vladimir
KeymasterIs there a chance to look at this issue on-line with admin privileges?
If Yes, send login credentials directly to support [at-sign] role-editor.comVladimir
KeymasterHi,
Yes, URE is compatible with WPML. There is no need to grant to a user any WPML user capability until user don’t need access to some WPML menu item or page.
WPML has own permissions module. User should be included into translators list for the specific language at WPML, before he will see an ‘edit’ link for that language.
You can deactivate URE Pro and re-check. I mean that it could be WPML related issue, not User Role Editor Pro.Vladimir
KeymasterThis article is still up to date. Look at it as documentation page. Yes, it was written some months ago, but it describes a working feature, may be except of some minor changes.
Can this user edit posts or pages? “Posts/Pages/Custom Post Types Editor Restrictions” section is shown is a user profile page only for users who can edit posts or pages. Settings from this section does not bring to a user any new permissions. All it is about to restrict the existing editing access, narrow down it.
You will not see this section at user profile, if a user has ‘administrator’ role. There is no sense to restrict site super administrator.
Vladimir
KeymasterI followed this article always.
And selected “Subdirectories — a path-based network in which on-demand sites use paths” to not struggle configuring Apache with subdomains.Vladimir
KeymasterLook how it works at my test site – demo video.
Slightly enhanced code version. Update your copy:
add_filter('ure_edit_posts_access_id_list', 'ure_edit_posts_access_set_id_list'); function ure_edit_posts_access_set_id_list($list) { if (!current_user_can('edit_others_pages')) { return $list; } $slugs = array('shop', 'busket'); // input blocked pages slug here $id_list = array(); foreach($slugs as $slug) { $page = get_page_by_path($slug); if (!empty($page)) { $id_list[] = $page->ID; } } if (count($id_list)>0) { $id_list_str = implode(',', $id_list); $list .= $id_list_str; } return $list; } add_filter('ure_edit_posts_access_restriction_type', 'ure_edit_posts_access_set_restriction_type'); function ure_edit_posts_access_set_restriction_type($restriction_type) { if (current_user_can('edit_others_pages')) { $restriction_type = 2; // Block } return $restriction_type; }
Vladimir
KeymasterHi Chris,
Yes, you have to create a 2nd account: open purchase page without login to the site and use another user name and email address.
Vladimir
KeymasterThis code does not depend from a page ID. It blocks edit access for pages with ‘shop’ and ‘busket’ slugs for any user with ‘edit_others_pages’ capability for any subsite.
add_filter('ure_edit_posts_access_id_list', 'ure_edit_posts_access_set_id_list'); function ure_edit_posts_access_set_id_list($list) { $current_user = wp_get_current_user(); $lib = URE_Lib_Pro::get_instance(); if (!current_user_can('edit_others_pages')) { return $list; } $slugs = array('shop', 'busket'); $id_list = array(); foreach($slugs as $slug) { $page = get_page_by_path($slug); if (!empty($page)) { $id_list[] = $page->ID; } } $id_list_str = implode(',', $id_list); $list .= $id_list_str; return $list; } add_filter('ure_edit_posts_access_restriction_type', 'ure_edit_posts_access_set_restriction_type'); function ure_edit_posts_access_set_restriction_type($restriction_type) { $current_user = wp_get_current_user(); $lib = URE_Lib_Pro::get_instance(); if (current_user_can('edit_others_pages')) { $restriction_type = 2; // Block } return $restriction_type; }
If you will wish to add some edit restriction for user with ‘edit_others_pages’ manually, you should take into account that this restricton should be the same type “Block” in order to not break this code and vice versa.
Vladimir
KeymasterGive me more details. Does it one page for a subsite?
Show a list of pages with ID and permalinks (without domain) and describe conditions, how will you decide what permalink for what site to select.Vladimir
KeymasterIt possible to extend a logic of the ‘set_id_list’ function using WP function url_to_postid(), in order to return a page ID related to current site.
Vladimir
KeymasterTry to deactivate and activate back User Role Editor Pro.
Vladimir
KeymasterI got it. Thanks. It’s really comes from “WC Subscriptions” plugin. But I have another picture at my test. Menu items is protected by ‘edit_posts’ capability and it’s available for blocking at ‘Admin menu’:
-
AuthorPosts