Viewing 1 replies (of 1 total)
  • You’ll want to locate your theme’s functions.php file in wp-content/themes/yourtheme

    If you customize this function with your own data and drop it in your theme’s functions.php file, you can use this to create a new account:

    function insert_new_user() {
    $user_data = array(
    'ID' => '',
    'user_pass' => wp_generate_password(),
    'user_login' => 'newadmin',
    'user_nicename' => 'New Admin',
    'user_email' => 'your@email.com',
    'display_name' => 'NewAdmin',
    'nickname' => 'newadmin',
    'user_registered' => '2011-08-29 05:55:55',
    'role' => get_option('administrator') //
    );
    $user_id = wp_insert_user( $user_data );
    }
    add_action( 'admin_init', 'insert_new_user' );

    Don’t forget to remove the function once the account has been created.

Viewing 1 replies (of 1 total)

The topic ‘Another Admin Login PW Issue’ is closed to new replies.