Parsed: 122595
<?php /** * These functions can be replaced via plugins. If plugins do not redefine these * functions, then these will be used instead. * * @package WordPress */ if ( ! function_exists( 'wp_set_current_user' ) ) : /* function wp_set_current_user() – Changes the current user by ID or name. */ endif; if ( ! function_exists( 'wp_get_current_user' ) ) : /* function wp_get_current_user() – Retrieve the current user object. */ endif; if ( ! function_exists( 'get_userdata' ) ) : /* function get_userdata() – Retrieve user info by user ID. */ endif; if ( ! function_exists( 'get_user_by' ) ) : /* function get_user_by() – Retrieves user info by a given field. */ endif; if ( ! function_exists( 'cache_users' ) ) : /* function cache_users() – Retrieves info for user lists to prevent multiple queries by get_userdata(). */ endif; if ( ! function_exists( 'wp_mail' ) ) : /* function wp_mail() – Sends an email, similar to PHP’s mail function. */ endif; if ( ! function_exists( 'wp_authenticate' ) ) : /* function wp_authenticate() – Authenticates a user, confirming the login credentials are valid. */ endif; if ( ! function_exists( 'wp_logout' ) ) : /* function wp_logout() – Log the current user out. */ endif; if ( ! function_exists( 'wp_validate_auth_cookie' ) ) : /* function wp_validate_auth_cookie() – Validates authentication cookie. */ endif; if ( ! function_exists( 'wp_generate_auth_cookie' ) ) : /* function wp_generate_auth_cookie() – Generates authentication cookie contents. */ endif; if ( ! function_exists( 'wp_parse_auth_cookie' ) ) : /* function wp_parse_auth_cookie() – Parses a cookie into its components. */ endif; if ( ! function_exists( 'wp_set_auth_cookie' ) ) : /* function wp_set_auth_cookie() – Sets the authentication cookies based on user ID. */ endif; if ( ! function_exists( 'wp_clear_auth_cookie' ) ) : /* function wp_clear_auth_cookie() – Removes all of the cookies associated with authentication. */ endif; if ( ! function_exists( 'is_user_logged_in' ) ) : /* function is_user_logged_in() – Determines whether the current visitor is a logged in user. */ endif; if ( ! function_exists( 'auth_redirect' ) ) : /* function auth_redirect() – Checks if a user is logged in, if not it redirects them to the login page. */ endif; if ( ! function_exists( 'check_admin_referer' ) ) : /* function check_admin_referer() – Ensures intent by verifying that a user was referred from another admin page with the correct security nonce. */ endif; if ( ! function_exists( 'check_ajax_referer' ) ) : /* function check_ajax_referer() – Verifies the Ajax request to prevent processing requests external of the blog. */ endif; if ( ! function_exists( 'wp_redirect' ) ) : /* function wp_redirect() – Redirects to another page. */ endif; if ( ! function_exists( 'wp_sanitize_redirect' ) ) : /* function wp_sanitize_redirect() – Sanitizes a URL for use in a redirect. */ /* function _wp_sanitize_utf8_in_redirect() – URL encode UTF-8 characters in a URL. */ endif; if ( ! function_exists( 'wp_safe_redirect' ) ) : /* function wp_safe_redirect() – Performs a safe (local) redirect, using wp_redirect(). */ endif; if ( ! function_exists( 'wp_validate_redirect' ) ) : /* function wp_validate_redirect() – Validates a URL for use in a redirect. */ endif; if ( ! function_exists( 'wp_notify_postauthor' ) ) : /* function wp_notify_postauthor() – Notify an author (and/or others) of a comment/trackback/pingback on a post. */ endif; if ( ! function_exists( 'wp_notify_moderator' ) ) : /* function wp_notify_moderator() – Notifies the moderator of the site about a new comment that is awaiting approval. */ endif; if ( ! function_exists( 'wp_password_change_notification' ) ) : /* function wp_password_change_notification() – Notify the blog admin of a user changing password, normally via email. */ endif; if ( ! function_exists( 'wp_new_user_notification' ) ) : /* function wp_new_user_notification() – Emails login credentials to a newly-registered user. */ endif; if ( ! function_exists( 'wp_nonce_tick' ) ) : /* function wp_nonce_tick() – Returns the time-dependent variable for nonce creation. */ endif; if ( ! function_exists( 'wp_verify_nonce' ) ) : /* function wp_verify_nonce() – Verifies that a correct security nonce was used with time limit. */ endif; if ( ! function_exists( 'wp_create_nonce' ) ) : /* function wp_create_nonce() – Creates a cryptographic token tied to a specific action, user, user session, and window of time. */ endif; if ( ! function_exists( 'wp_salt' ) ) : /* function wp_salt() – Returns a salt to add to hashes. */ endif; if ( ! function_exists( 'wp_hash' ) ) : /* function wp_hash() – Get hash of given string. */ endif; if ( ! function_exists( 'wp_hash_password' ) ) : /* function wp_hash_password() – Create a hash (encrypt) of a plain text password. */ endif; if ( ! function_exists( 'wp_check_password' ) ) : /* function wp_check_password() – Checks the plaintext password against the encrypted Password. */ endif; if ( ! function_exists( 'wp_generate_password' ) ) : /* function wp_generate_password() – Generates a random password drawn from the defined set of characters. */ endif; if ( ! function_exists( 'wp_rand' ) ) : /* function wp_rand() – Generates a random non-negative number. */ endif; if ( ! function_exists( 'wp_set_password' ) ) : /* function wp_set_password() – Updates the user’s password with a new encrypted one. */ endif; if ( ! function_exists( 'get_avatar' ) ) : /* function get_avatar() – Retrieves the avatar `<img>` tag for a user, email address, MD5 hash, comment, or post. */ endif; if ( ! function_exists( 'wp_text_diff' ) ) : /* function wp_text_diff() – Displays a human readable HTML representation of the difference between two strings. */ endif;