wp_logout()
Log the current user out.
Description Description
Source Source
File: wp-includes/pluggable.php
function wp_logout() { wp_destroy_current_session(); wp_clear_auth_cookie(); wp_set_current_user( 0 ); /** * Fires after a user is logged-out. * * @since 1.5.0 */ do_action( 'wp_logout' ); }
Expand full source code Collapse full source code View on Trac
Changelog Changelog
Version | Description |
---|---|
2.5.0 | Introduced. |
User Contributed Notes User Contributed Notes
You must log in before being able to contribute a note or feedback.
Example