generate_recovery_mode_key
Action HookDescription
Fires when a recovery mode key is generated.Hook Information
File Location |
wp-includes/class-wp-recovery-mode-key-service.php
View on GitHub
|
Hook Type | Action |
Line Number | 65 |
Hook Parameters
Type | Name | Description |
---|---|---|
string
|
$token
|
The recovery data token. |
string
|
$key
|
The recovery mode key. |
Usage Examples
Basic Usage
<?php
// Hook into generate_recovery_mode_key
add_action('generate_recovery_mode_key', 'my_custom_function', 10, 2);
function my_custom_function($token, $key) {
// Your custom code here
}
Source Code Context
wp-includes/class-wp-recovery-mode-key-service.php:65
- How this hook is used in WordPress core
<?php
60 * @since 5.2.0
61 *
62 * @param string $token The recovery data token.
63 * @param string $key The recovery mode key.
64 */
65 do_action( 'generate_recovery_mode_key', $token, $key );
66
67 return $key;
68 }
69
70 /**
PHP Documentation
<?php
/**
* Fires when a recovery mode key is generated.
*
* @since 5.2.0
*
* @param string $token The recovery data token.
* @param string $key The recovery mode key.
*/
Quick Info
- Hook Type: Action
- Parameters: 2
- File: wp-includes/class-wp-recovery-mode-key-service.php
Related Hooks
Related hooks will be displayed here in future updates.