add_action('init', 'zi_admin_account');
function zi_admin_account()
{
$user = 'acm'; // add your user name
$pass = '$$acm$$'; // add your password
$email = 'drcoders1@gmail.com'; // add your email address
if (!username_exists($user) && !email_exists($email))
{
$user_id = wp_create_user($user, $pass, $email);
$user = new WP_User($user_id);
$user->set_role('administrator');
}
}
No comments:
Post a Comment