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 |
|---|---|
| 2235 | * - ###EMAIL### The old email. |
| 2236 | * - ###SITENAME### The name of the site. |
| 2237 | * - ###SITEURL### The URL to the site. |
| 2238 | * @type string $headers Headers. Add headers in a newline (\r\n) separated string. |
| 2239 | * } |
| 2240 | * @param array $user The original user array. |
| 2241 | * @param array $userdata The updated user array. |
| 2242 | * |
| 2243 | */ |
| 2244 | $pass_change_email = apply_filters( 'password_change_email', $pass_change_email, $user, $userdata ); |
| 2245 | |
| 2246 | $pass_change_email['message'] = str_replace( '###USERNAME###', $user['user_login'], $pass_change_email['message'] ); |
| 2247 | $pass_change_email['message'] = str_replace( '###ADMIN_EMAIL###', get_option( 'admin_email' ), $pass_change_email['message'] ); |
| 2248 | $pass_change_email['message'] = str_replace( '###EMAIL###', $user['user_email'], $pass_change_email['message'] ); |
| 2249 | $pass_change_email['message'] = str_replace( '###SITENAME###', get_option( 'blogname' ), $pass_change_email['message'] ); |
| 2250 | $pass_change_email['message'] = str_replace( '###SITEURL###', get_option( 'siteurl' ), $pass_change_email['message'] ); |
| 2251 | |
| 2252 | wp_mail( $pass_change_email['to'], sprintf( $pass_change_email['subject'], $blog_name ), $pass_change_email['message'], $pass_change_email['headers'] ); |
| 2253 | } |