signup_user_init
Filter HookDescription
Filters the default user variables used on the user sign-up form. }Hook Information
File Location |
wp-signup.php
View on GitHub
|
Hook Type | Filter |
Line Number | 619 |
Hook Parameters
Type | Name | Description |
---|---|---|
array
|
$signup_user_defaults
|
{ An array of default user variables. |
Usage Examples
Basic Usage
<?php
// Hook into signup_user_init
add_filter('signup_user_init', 'my_custom_filter', 10, 1);
function my_custom_filter($signup_user_defaults) {
// Your custom filtering logic here
return $signup_user_defaults;
}
Source Code Context
wp-signup.php:619
- How this hook is used in WordPress core
<?php
614 * @type string $user_name The user username.
615 * @type string $user_email The user email address.
616 * @type WP_Error $errors A WP_Error object with possible errors relevant to the sign-up user.
617 * }
618 */
619 $filtered_results = apply_filters( 'signup_user_init', $signup_user_defaults );
620 $user_name = $filtered_results['user_name'];
621 $user_email = $filtered_results['user_email'];
622 $errors = $filtered_results['errors'];
623
624 ?>
PHP Documentation
<?php
/**
* Filters the default user variables used on the user sign-up form.
*
* @since 3.0.0
*
* @param array $signup_user_defaults {
* An array of default user variables.
*
* @type string $user_name The user username.
* @type string $user_email The user email address.
* @type WP_Error $errors A WP_Error object with possible errors relevant to the sign-up user.
* }
*/
Quick Info
- Hook Type: Filter
- Parameters: 1
- File: wp-signup.php
Related Hooks
Related hooks will be displayed here in future updates.