Hide payment method based on user role AND minimum cart value
Hide payment method based on user role AND minimum cart value
Hide payment method based on user role AND minimum cart value
How to only display all posts to a custom User Role?
This is not possible using the capabilities system, the granularity you want does not exist in WP core: edit_posts Since 2.0 Allows access to Administration Screens options: Posts Posts > Add New Comments Comments > Awaiting Moderation https://wordpress.org/support/article/roles-and-capabilities/#edit_posts edit_posts covers both viewing, adding, and editing posts, as well as commenting. There is a capability that … Read more
I manage to filter the posts, this seems to be enough for this project function remove_notallowed_authors( $query ) { $user = wp_get_current_user(); if ( in_array( ‘editor_group_role’, (array) $user->roles ) ) { $user_ids = get_users( [ ‘role’ => ‘user_role_that_posted’, ‘fields’ => ‘ID’ ] ); $query->set( ‘author__in’, $user_ids ); } } add_action( ‘pre_get_posts’, ‘remove_notallowed_authors’ );
On a multisite, the ‘super-admin’ is the only one that gets to see the ‘master’ site. Admins can see their individual sub-sites. The super-admin can admin all the sub-sites.
You can use a subdomain for every site. Then it’s easy to separate the users per wp-config.php: $base = str_replace( ‘.’, ‘_’, filter_input( INPUT_SERVER, , ‘SERVER_NAME’ ); const CUSTOM_USER_TABLE $base . ‘_users’; const CUSTOM_USER_META_TABLE . ‘_usermeta’; unset($base); // clean up
Don’t know if there is plugin for this or not, you should try by searching “restrict page by user roles” in WordPress directory. But if you can code and know few conditional tags and how to use them then I think you should try following snippet and it will work for you. But Beware, this … Read more
How to hide Add new Term area for taxonomy terms for specific role (Client)
Language per user role, how can I achieve this?
current_user_can( ‘edit_user’ ) does not work