Anton Putau
Anton Putau

Reputation: 762

Create user on wordpress programmatically

Is there any opportunity to create user from nodejs? May be there is some native wp api or a plugins exists? I am using wordpess 4.5 Thanks.

Upvotes: 1

Views: 730

Answers (2)

Steven Roh
Steven Roh

Reputation: 36

If you plan to update your WordPress to 4.7+*, you can use the WP-API :

See Create a User on this page http://v2.wp-api.org/reference/users/

*The REST API is included in WordPress 4.7! Plugins are no longer required, just install the latest version of WordPress and you're ready to go.

The plugin is a legacy version for 4.4 and later : https://wordpress.org/plugins/rest-api/

Upvotes: 1

Marina Lebedeva
Marina Lebedeva

Reputation: 139

Can you send an Ajax request to the system?

More info:

https://codex.wordpress.org/AJAX_in_Plugins

https://wp-kama.ru/id_2018/ajax-v-wordpress.html (Very good article in Russian, examples are working)

Function for create new user in system:

register_new_user($user_login, $user_email);

Upvotes: 1

Related Questions