wphooks.info - clear_auth_cookie

clear_auth_cookie

The hook occurs in the following file:

wp-includes/pluggable.php:
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
 * Removes all of the cookies associated with authentication.
 *
 * @since 2.5.0
 */
function wp_clear_auth_cookie() {
	/**
	 * Fires just before the authentication cookies are cleared.
	 *
	 * @since 2.7.0
	 */
	do_action( 'clear_auth_cookie' );

	/** This filter is documented in wp-includes/pluggable.php */
	if ( ! apply_filters( 'send_auth_cookies', true ) ) {
		return;
	}

	// Auth cookies
	setcookie( AUTH_COOKIE,        ' ', time() - YEAR_IN_SECONDS, ADMIN_COOKIE_PATH,   COOKIE_DOMAIN );
	setcookie( SECURE_AUTH_COOKIE, ' ', time() - YEAR_IN_SECONDS, ADMIN_COOKIE_PATH,   COOKIE_DOMAIN );