- This topic has 5 replies, 3 voices, and was last updated 6 years, 7 months ago by .
Viewing 6 posts - 1 through 6 (of 6 total)
Viewing 6 posts - 1 through 6 (of 6 total)
- You must be logged in to reply to this topic.
Support site for Tips and Tricks HQ premium products
by
Tips and Tricks HQ Support Portal › Forums › WP Photo Seller › User Role Permissions (Don't want Photo Seller user to be Admin)
Tagged: User Role Permissions
Hi
I am a WordPress Admin and I want my client to be able to access all Photo Seller functions without being an Admin themselves.
If I make my client an Editor (or anything less) they cannot access WP Photo Seller.
Is there a solution to this please?
Hi,
Yes there is a filter you can use.
Put the following in your theme’s functions.php
add_filter("wpps_menu_capability", "wpps_change_mgmt_permissions", 10, 1);
function wpps_change_mgmt_permissions($permission){
return "publish_pages";
}
Thanks Peter – worked like a charm
Hi,
Thanks for the above answer, it is very helpful, but I was wondering if/how I could choose which role(s) I wish to use the plugin.
I use the User Role Editor plugin on my site. Is there a “capability” I can add to my chosen roles? If I do it this way will I still need the above code in the functions.php?
Thanks
Hi,
If you want to change the role which can access the photo seller plugin you will need to choose a different capability and replace “publish_pages” in the code sample with the new one.
For a list of roles/capabilities see the following:
Cheers Peter, this is working exactly as I was hoping. I was able to create a new capability called “photo_seller” and apply that to the custom role I created and replace it in the code above. Now only the custom role and Administrator can see the photo seller plugin