A WordPress-centric search engine for devs and theme authors

wp-includes/user.php › WordPress File

Core User API

Function Short description
add_user_metaAdds meta data to a user.
check_password_reset_keyRetrieves a user row based on password reset key and login
clean_user_cacheClean all user caches
count_many_users_postsNumber of posts written by a list of users.
count_usersCount number of users who have each of the user roles.
count_user_postsNumber of posts user has written.
delete_user_metaRemove metadata matching criteria from a user.
delete_user_optionDelete user option with global blog capability.
email_existsDetermines whether the given email exists.
get_blogs_of_userGet the sites a user belongs to.
get_current_user_idGet the current user's ID
get_password_reset_keyCreates, stores, then returns a password reset key for user.
get_usersRetrieve list of users matching criteria.
get_user_metaRetrieve user meta field for a user.
get_user_optionRetrieve user option that can be either per Site or per Network.
is_user_member_of_blogFind out whether a user is a member of a given blog.
new_user_email_admin_noticeAdds an admin notice alerting the user to check for confirmation request email after email address change.
register_new_userHandles registering a new user.
reset_passwordHandles resetting the user's password.
retrieve_passwordHandles sending a password retrieval email to a user.
sanitize_user_fieldSanitize user field based on context.
send_confirmation_on_profile_emailSend a confirmation request email when a change of user email address is attempted.
setup_userdataSet up global user vars.
update_user_cachesUpdate all user caches
update_user_metaUpdate user meta field based on user ID.
update_user_optionUpdate user option with global blog capability.
username_existsDetermines whether the given username exists.
validate_usernameChecks whether a username is valid.
wp_authenticate_application_passwordAuthenticates the user using an application password.
wp_authenticate_cookieAuthenticate the user using the WordPress auth cookie.
wp_authenticate_email_passwordAuthenticates a user using the email and password.
wp_authenticate_spam_checkFor Multisite blogs, check if the authenticated user has been marked as a spammer, or if the user's primary blog has been marked as spam.
wp_authenticate_username_passwordAuthenticate a user, confirming the username and password are valid.
wp_create_userA simpler way of inserting a user into the database.
wp_create_user_requestCreate and log a user request to perform a specific action.
wp_destroy_all_sessionsRemove all session tokens for the current user from the database.
wp_destroy_current_sessionRemove the current session token from the database.
wp_destroy_other_sessionsRemove all but the current session token for the current user for the database.
wp_dropdown_usersCreate dropdown HTML content of users.
wp_generate_user_request_keyReturns a confirmation key for a user action and stores the hashed version for future comparison.
wp_get_all_sessionsRetrieve a list of sessions for the current user.
wp_get_password_hintGets the text suggesting how to create strong passwords.
wp_get_session_tokenRetrieve the current session token from the logged_in cookie.
wp_get_users_with_no_roleGet the user IDs of all users with no role on this site.
wp_get_user_contact_methodsSet up the user contact methods.
wp_get_user_requestReturn the user request object for the specified request ID.
wp_insert_userInsert a user into the database.
wp_is_application_passwords_availableChecks if Application Passwords is globally available.
wp_is_application_passwords_available_for_userChecks if Application Passwords is available for a specific user.
wp_is_application_passwords_supportedChecks if Application Passwords is supported.
wp_list_usersList all the users of the site, with several options available.
wp_register_user_personal_data_exporterRegisters the personal data exporter for users.
wp_send_new_user_notificationsInitiates email notifications related to the creation of new users.
wp_send_user_requestSend a confirmation request email to confirm an action.
wp_signonAuthenticates and logs a user in with 'remember' capability.
wp_update_userUpdate a user in the database.
wp_user_personal_data_exporterFinds and exports personal data associated with an email address from the user and user_meta table.
wp_user_request_action_descriptionGet action description from the name and return a string.
wp_validate_application_passwordValidates the application password credentials passed via Basic Authentication.
wp_validate_logged_in_cookieValidates the logged-in cookie.
wp_validate_user_request_keyValidate a user request by comparing the key with the request's key.
_get_additional_user_keysReturns a list of meta keys to be (maybe) populated in wp_update_user().
_wp_get_current_userRetrieves the current user object.
_wp_get_user_contactmethodsThe old private function for setting up user contact methods.
_wp_privacy_account_request_confirmedUpdate log when privacy request is confirmed.
_wp_privacy_account_request_confirmed_messageReturn request confirmation message HTML.
_wp_privacy_action_request_typesGet all personal data request types.
_wp_privacy_send_erasure_fulfillment_notificationNotify the user when their erasure request is fulfilled.
_wp_privacy_send_request_confirmation_notificationNotify the site administrator via email when a request is confirmed.