Answer the question
In order to leave comments, you need to log in
wp_insert_user() function with admin approval option?
Good afternoon!
Please tell me, I am using the wp_insert_user() function to register users.
I need to implement site administrator registration approval.
How can I implement this?
Thank you all in advance!
Answer the question
In order to leave comments, you need to log in
https://jsfiddle.net/r41jx2q5/
I hope the point is clear
Good question. I myself am increasingly thinking about the approval of user registration.
Restricting a role to a newly registered person doesn't work for me - I'll have quite a few rejected registrations. And that means a lot of empty accounts. Why do I need empty accounts?
So far, at the moment I have this option in my head:
A PRE-registration page is being created. The user in input specifies login, mail, etc.
All this is generated in a certain link, which comes to my mail with a letter.
If I follow this link, then a user is created through wp_insert_user () with the data specified by him. And if I do not need this user, I simply delete the letter with this link.
The solution, of course, is not ideal, but I have not yet come up with anything more beautiful.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question