Action hook 'clear_auth_cookie'

in WP Core File wp-includes/pluggable.php at line 1129

View Source

clear_auth_cookie

Action Hook
Description
Fires just before the authentication cookies are cleared.

Hook Information

File Location wp-includes/pluggable.php View on GitHub
Hook Type Action
Line Number 1129

Hook Parameters

This hook doesn't accept any parameters.

Usage Examples

Basic Usage
<?php
// Hook into clear_auth_cookie
add_action('clear_auth_cookie', 'my_custom_function');

function my_custom_function() {
    // Your custom code here
}

Source Code Context

wp-includes/pluggable.php:1129 - How this hook is used in WordPress core
<?php
1124  		/**
1125  		 * Fires just before the authentication cookies are cleared.
1126  		 *
1127  		 * @since 2.7.0
1128  		 */
1129  		do_action( 'clear_auth_cookie' );
1130  
1131  		/** This filter is documented in wp-includes/pluggable.php */
1132  		if ( ! apply_filters( 'send_auth_cookies', true, 0, 0, 0, '', '' ) ) {
1133  			return;
1134  		}

PHP Documentation

<?php
/**
		 * Fires just before the authentication cookies are cleared.
		 *
		 * @since 2.7.0
		 */
Quick Info
  • Hook Type: Action
  • Parameters: 0
  • File: wp-includes/pluggable.php
Related Hooks

Related hooks will be displayed here in future updates.