Warning: This function has been deprecated. Use wp_create_user() instead.
create_user() WordPress Function
The create_user() function allows you to create a new user in WordPress. This function takes four arguments: the user's login, the user's email, the user's password, and the user's role. The user's role can be either 'subscriber' or 'administrator'.
create_user( string $username, string $password, string $email ) #
An alias of wp_create_user().
Description
See also
Parameters
- $username
(string)(Required)The user's username.
- $password
(string)(Required)The user's password.
(string)(Required)The user's email.
Return
(int) The new user's ID.
Source
File: wp-includes/deprecated.php
function create_user($username, $password, $email) { _deprecated_function( __FUNCTION__, '2.0.0', 'wp_create_user()' ); return wp_create_user($username, $password, $email); }
Expand full source codeCollapse full source codeView on TracView on GitHub
Changelog
Version | Description |
---|---|
2.0.0 | Introduced. |