function user_pass_ok($user_login, $user_pass) {}

Check that the user login name and password is correct.


  • string $user_login: User name.
  • string $user_pass: User password.

Return values

returns:False if does not authenticate, true if username and password authenticates.

Source code

function user_pass_ok($user_login, $user_pass) {

	$user = wp_authenticate($user_login, $user_pass);

	if ( is_wp_error($user) )

		return false;

	return true;



No comments yet... Be the first to leave a reply!

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: