get_userdatabylogin

Retrieve user info by login name.

Description

(bool|object) get_userdatabylogin( (string) $user_login ); 

Returns (bool|object)

False on failure, User DB row object

Parameters (1)

0. $user_login (string)
The user login.

Usage

  1. if ( !function_exists( 'get_userdatabylogin' ) ) { 
  2. require_once ABSPATH . WPINC . '/pluggable-deprecated.php'; 
  3.  
  4. // The user login. 
  5. $user_login = ''; 
  6.  
  7. // NOTICE! Understand what this does before running. 
  8. $result = get_userdatabylogin($user_login); 
  9.  

Defined (1)

The function is defined in the following location(s).

/wp-includes/pluggable-deprecated.php  
  1. function get_userdatabylogin($user_login) { 
  2. _deprecated_function( __FUNCTION__, '3.3.0', "get_user_by('login')" ); 
  3. return get_user_by('login', $user_login);