WP hooks navigation: Home/browse • Actions index • Filters index
To save our bandwidth, we show only a snippet of code around each occurence of the hook. View complete file in SVN (without highlighting).
The best way to understand what a hook does is to look at where it occurs in the source code.
do_action( "hook_name" )
apply_filters( "hook_name", "what_to_filter" )
.Remember, this hook may occur in more than one file. Moreover, the hook's context may change from version to version.
Line | Code |
---|---|
89 | $user_login = ''; |
90 | $user_pass = ''; |
91 |
|
92 | if ( $_POST ) { |
93 | if ( empty( $_POST['user_login'] ) ) |
94 | $errors['user_login'] = __('<strong>ERROR</strong>: The username field is empty.'); |
95 | if ( empty( $_POST['user_email'] ) ) |
96 | $errors['user_email'] = __('<strong>ERROR</strong>: The e-mail field is empty.'); |
97 |
|
98 | do_action('lostpassword_post'); |
99 |
|
100 | if ( empty( $errors ) ) { |
101 | $user_data = get_userdatabylogin(trim($_POST['user_login'])); |
102 | // redefining user_login ensures we return the right case in the email |
103 | $user_login = $user_data->user_login; |
104 | $user_email = $user_data->user_email; |
105 |
|
106 | if (!$user_email || $user_email != $_POST['user_email']) { |
107 | $errors['invalidcombo'] = __('<strong>ERROR</strong>: Invalid username / e-mail combination.'); |