• Resolved HS79

    (@hs79)


    I use the Members plugin along with New User Approve. I also use another plugin that allows account creation and login via social media networks and Google.

    How do I assign a role that prevents new accounts from creating new posts or posting comments until they have been approved? How can a role been assigned so that New User Approve plugin assigns a limited role until approved?

    Users who use social networks or Google to create an account can circumvent this plugin and use site because the default role allows submissions. How can we make New User Approve change roles based on approval/disapproval?

    If there is a way to allow all new accounts to be assigned ‘Subscriber’ role until admin manually approves the account via your plugin and then change to ‘Author’ or another role after approval, it would be ideal.

    Currently, in the Members plugin settings, ‘Subscriber’ is not default role. Does this setting determine which role new accounts are assigned until approval? Will your plugin change the role automatically to another role after approval?

Viewing 2 replies - 1 through 2 (of 2 total)
  • Hi @hs79,

    Thank you for using New User Approve,

    No, the plugin does not make any kind of changes to roles. It just adds a new meta field through which the user’s status can be determined.
    The users with ‘pending’ and ‘denied’ status should not be able to login to the site, only the users with ‘approved’ status should be able to login to the site.

    You can use the below filter to assign custom roles to users when they register (pending status, you can apply the role to the user and return the welcome message as it is)
    apply_filters( 'new_user_approve_welcome_user_message', $message, $user_email );

    You can use the below action to assign custom role to user when their status changes to active
    do_action( 'new_user_approve_user_approved', $user );

    Thanks

    Hi @hs79,

    Due to a lack of activity, we are going to mark this thread as resolved. If you have any other issues, please feel free to open a new thread.

    Thanks

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘How to assign a new role to accounts pending approval?’ is closed to new replies.