Change WordPress user roles and capabilities › Forums › How to or FAQ › Can't revoke access custom post types
- This topic has 25 replies, 2 voices, and was last updated 7 years, 5 months ago by Vladimir.
-
AuthorPosts
-
06/06/2017 at 16:15 #3832[email protected]Participant
Hi there,
I would like to delete some menu items & access for our client role.
Unfortunate I can’t see these access. It’s all showing (0/0).
Anybody here to help me out? I got a paid Pro license.
Please find screenshots attached:
https://drive.google.com/open?id=0Bz4EyMuUPGVGdXVUclN5TWRybkE
https://drive.google.com/file/d/0Bz4EyMuUPGVGRFRfYjkzeXZjZ2s/view?usp=sharingMany thanks in advance!
07/06/2017 at 05:52 #3835VladimirKeymasterHi,
URE shows (0/0) for a custom post type (CPT) if it users WordPress built-in ‘post’ based capabilities set, like ‘edit_posts’, ‘edit_published_posts’, etc.
You have two alternative options to block CPT menu for the role:
1) use admin menu access add-on for it.2) activate “Force custom post types to use their own capabilities” option at the Settings->User Role Editor->Additional Modules tab. It will require to modify existing roles to provide access to the custom post type. Conflicts with some plugins are possible.
15/06/2017 at 12:52 #3872[email protected]ParticipantHi Vladimir,
Thank you for the reply. So far this worked well on the majority of the options. However in our WP quiz pro we have a few functionalities we do want the client to have. However I cannot seem to find where to enable them for our client. Its possible to let him add or remove things, however we only want him to see the “players” and “email subscribers tab”. Is there a way I can do this, and where? Do let me know if you need access to the admin area.
16/06/2017 at 02:58 #3875VladimirKeymasterYes, I need to make a closer look at admin area. Send credentials to support [at-sign]role-editor.com
Show a screenshot with marked areas, to which you wish provide access for a client.19/06/2017 at 12:38 #3878[email protected]ParticipantWe’ve sent an email regarding this issue. Hopefully you’ll be able to look quickly into this matter.
19/06/2017 at 16:47 #3879VladimirKeymasterThanks. I answered to you by email. Let me know if you need a further help.
I repeat my answer here if it will be useful for someone other:General steps when you don’t know what permissions are required for some admin menu items:
– Open Users->User Role Editor
– Select ‘Administrator’ role
– Open “Admin menu”
– Find needed menu item and look what capability protects it. “WP Quiz->Players” is protected by ‘manage_options”.
– Close “Admin menu” window
– Select other role
– Add required capability (‘manage_options’ in this case) to this role
– Update it.
– Open ‘Admin menu’ for this role
– Block unneeded menu items for this role.22/06/2017 at 11:37 #3886[email protected]ParticipantHi Vladimir,
This worked so far great. However I seem to struggle with the permissions on My Testimonials. I’ve currently disabled them all together as the page will say I do not have permissions once I try enter it. Firstly this had to do with a wp_options table bug in the database and I reset all the data there for a clean database table. Then I started configuring the plugin again, and now I do not have access to it…again, even with admin permissions.
Can you help me look into this, and hopefully fix it. As I think somewhere the plugin puts the permissions off. Do let me know, the login settings sent through email should be the same still.
The portfolio has been put on blocked in the admin menu, however its still visible on the side. Why?
22/06/2017 at 18:13 #3887VladimirKeymasterHi Benny,
Can you share for me ‘My Testimonials’ plugin copy via dropbox or similar service. I will look on its permissions at my local development environment.
22/06/2017 at 18:28 #3888VladimirKeymasterI reproduced the issue with ‘Portfolio post type’ plugin. I will investigate it and inform you about a result.
23/06/2017 at 12:40 #3890[email protected]ParticipantHI Vladimir,
Keep me up to date. Really looking forward to your solution!
24/06/2017 at 05:32 #3891VladimirKeymasterHi Benny,
You helped me to find a bug in admin menu access add-on. Thanks. I will develop a fix next week as I return home from a short trip. It will take some time for testing before I can to publish the update.
A quick workaround is to add ‘edit_portfolios’ capability to the role and block all ‘Portrolio’ menu items via the same admin menu access add-on. I did this at your site and user with ‘Klant’ role does not have access to the ‘Portfolio’ menu.
27/06/2017 at 07:29 #3899[email protected]ParticipantI must have overseen the request for the My Testimonial plugin. I will send you a WeTransfer with the files from the plugin. Hopefully you’ll be able to identify the restriction issue too!
Do let me know.
27/06/2017 at 09:48 #3900[email protected]ParticipantWe also do not have access to WPML anymore. Is this because of User role too?
29/06/2017 at 05:15 #3906VladimirKeymasterI got ‘My Testimonial’ plugin. Thanks. I don’t see any problem with access to it at my test installation. It’s a capabilities set for WP built-in ‘post’ by default or capabilities set for ‘imtst_testimonials’ custom post type in case you turned ON URE Pro’s option ‘force custom post types to use own capabilities’.
I tried to look on the current settings at your site, but a user you provided to me does not have admin privileges currently.
I will can to say more on WPML too if/when you refresh my access to your site.
29/06/2017 at 11:25 #3910[email protected]ParticipantMy apologies, the access has been changed and you should have admin level access again.
Hopefully you can look what the current settings are, and explain to me where to changed these. This would help for future changes!
Hopefully you’ll also be able to fix WPML then.
Looking forward to your reply.
-
AuthorPosts
- You must be logged in to reply to this topic.