Support Forum
Hi support i have added the subscriber capability to upload files
it works when i create new user after when i change password from admin the same user can not upload file even he has cpapbility upload file assigned following my code
function mb_allow_subscriber_uploads() {
if ( is_admin() ) {
return;
}
// Replace 'subscriber' with the required role to update, can also be contributor.
$subscriber = get_role( 'subscriber' );
$subscriber->add_cap( 'upload_files' );
}
add_action( 'init', 'mb_allow_subscriber_uploads' );
this code i added in functions.php
waiting for your reply.