| 2267 | | $pass_change_email = array( |
| 2268 | | 'to' => $user['user_email'], |
| 2269 | | /* translators: Password change notification email subject. %s: Site title. */ |
| 2270 | | 'subject' => __( '[%s] Password Changed' ), |
| 2271 | | 'message' => $pass_change_text, |
| 2272 | | 'headers' => '', |
| 2273 | | ); |
| | 2269 | $pass_change_email = array( |
| | 2270 | 'to' => $user['user_email'], |
| | 2271 | /* translators: Password change notification email subject. %s: Site title. */ |
| | 2272 | 'subject' => __( '[%s] Password Changed' ), |
| | 2273 | 'message' => $pass_change_text, |
| | 2274 | 'headers' => '', |
| | 2275 | ); |
| 2275 | | /** |
| 2276 | | * Filters the contents of the email sent when the user's password is changed. |
| 2277 | | * |
| 2278 | | * @since 4.3.0 |
| 2279 | | * |
| 2280 | | * @param array $pass_change_email { |
| 2281 | | * Used to build wp_mail(). |
| 2282 | | * |
| 2283 | | * @type string $to The intended recipients. Add emails in a comma separated string. |
| 2284 | | * @type string $subject The subject of the email. |
| 2285 | | * @type string $message The content of the email. |
| 2286 | | * The following strings have a special meaning and will get replaced dynamically: |
| 2287 | | * - ###USERNAME### The current user's username. |
| 2288 | | * - ###ADMIN_EMAIL### The admin email in case this was unexpected. |
| 2289 | | * - ###EMAIL### The user's email address. |
| 2290 | | * - ###SITENAME### The name of the site. |
| 2291 | | * - ###SITEURL### The URL to the site. |
| 2292 | | * @type string $headers Headers. Add headers in a newline (\r\n) separated string. |
| 2293 | | * } |
| 2294 | | * @param array $user The original user array. |
| 2295 | | * @param array $userdata The updated user array. |
| 2296 | | */ |
| 2297 | | $pass_change_email = apply_filters( 'password_change_email', $pass_change_email, $user, $userdata ); |
| | 2277 | /** |
| | 2278 | * Filters the contents of the email sent when the user's password is changed. |
| | 2279 | * |
| | 2280 | * @since 4.3.0 |
| | 2281 | * |
| | 2282 | * @param array $pass_change_email { |
| | 2283 | * Used to build wp_mail(). |
| | 2284 | * |
| | 2285 | * @type string $to The intended recipients. Add emails in a comma separated string. |
| | 2286 | * @type string $subject The subject of the email. |
| | 2287 | * @type string $message The content of the email. |
| | 2288 | * The following strings have a special meaning and will get replaced dynamically: |
| | 2289 | * - ###USERNAME### The current user's username. |
| | 2290 | * - ###ADMIN_EMAIL### The admin email in case this was unexpected. |
| | 2291 | * - ###EMAIL### The user's email address. |
| | 2292 | * - ###SITENAME### The name of the site. |
| | 2293 | * - ###SITEURL### The URL to the site. |
| | 2294 | * @type string $headers Headers. Add headers in a newline (\r\n) separated string. |
| | 2295 | * } |
| | 2296 | * @param array $user The original user array. |
| | 2297 | * @param array $userdata The updated user array. |
| | 2298 | */ |
| | 2299 | $pass_change_email = apply_filters( 'password_change_email', $pass_change_email, $user, $userdata ); |
| 2299 | | $pass_change_email['message'] = str_replace( '###USERNAME###', $user['user_login'], $pass_change_email['message'] ); |
| 2300 | | $pass_change_email['message'] = str_replace( '###ADMIN_EMAIL###', get_option( 'admin_email' ), $pass_change_email['message'] ); |
| 2301 | | $pass_change_email['message'] = str_replace( '###EMAIL###', $user['user_email'], $pass_change_email['message'] ); |
| 2302 | | $pass_change_email['message'] = str_replace( '###SITENAME###', $blog_name, $pass_change_email['message'] ); |
| 2303 | | $pass_change_email['message'] = str_replace( '###SITEURL###', home_url(), $pass_change_email['message'] ); |
| | 2301 | $pass_change_email['message'] = str_replace( '###USERNAME###', $user['user_login'], $pass_change_email['message'] ); |
| | 2302 | $pass_change_email['message'] = str_replace( '###ADMIN_EMAIL###', get_option( 'admin_email' ), $pass_change_email['message'] ); |
| | 2303 | $pass_change_email['message'] = str_replace( '###EMAIL###', $user['user_email'], $pass_change_email['message'] ); |
| | 2304 | $pass_change_email['message'] = str_replace( '###SITENAME###', $blog_name, $pass_change_email['message'] ); |
| | 2305 | $pass_change_email['message'] = str_replace( '###SITEURL###', home_url(), $pass_change_email['message'] ); |
| 2308 | | if ( ! empty( $send_email_change_email ) ) { |
| 2309 | | /* translators: Do not translate USERNAME, ADMIN_EMAIL, NEW_EMAIL, EMAIL, SITENAME, SITEURL: those are placeholders. */ |
| 2310 | | $email_change_text = __( |
| 2311 | | 'Hi ###USERNAME###, |
| | 2310 | if ( ! empty( $send_email_change_email ) ) { |
| | 2311 | /* translators: Do not translate USERNAME, ADMIN_EMAIL, NEW_EMAIL, EMAIL, SITENAME, SITEURL: those are placeholders. */ |
| | 2312 | $email_change_text = __( |
| | 2313 | 'Hi ###USERNAME###, |
| 2325 | | $email_change_email = array( |
| 2326 | | 'to' => $user['user_email'], |
| 2327 | | /* translators: Email change notification email subject. %s: Site title. */ |
| 2328 | | 'subject' => __( '[%s] Email Changed' ), |
| 2329 | | 'message' => $email_change_text, |
| 2330 | | 'headers' => '', |
| 2331 | | ); |
| | 2327 | $email_change_email = array( |
| | 2328 | 'to' => $user['user_email'], |
| | 2329 | /* translators: Email change notification email subject. %s: Site title. */ |
| | 2330 | 'subject' => __( '[%s] Email Changed' ), |
| | 2331 | 'message' => $email_change_text, |
| | 2332 | 'headers' => '', |
| | 2333 | ); |
| 2333 | | /** |
| 2334 | | * Filters the contents of the email sent when the user's email is changed. |
| 2335 | | * |
| 2336 | | * @since 4.3.0 |
| 2337 | | * |
| 2338 | | * @param array $email_change_email { |
| 2339 | | * Used to build wp_mail(). |
| 2340 | | * |
| 2341 | | * @type string $to The intended recipients. |
| 2342 | | * @type string $subject The subject of the email. |
| 2343 | | * @type string $message The content of the email. |
| 2344 | | * The following strings have a special meaning and will get replaced dynamically: |
| 2345 | | * - ###USERNAME### The current user's username. |
| 2346 | | * - ###ADMIN_EMAIL### The admin email in case this was unexpected. |
| 2347 | | * - ###NEW_EMAIL### The new email address. |
| 2348 | | * - ###EMAIL### The old email address. |
| 2349 | | * - ###SITENAME### The name of the site. |
| 2350 | | * - ###SITEURL### The URL to the site. |
| 2351 | | * @type string $headers Headers. |
| 2352 | | * } |
| 2353 | | * @param array $user The original user array. |
| 2354 | | * @param array $userdata The updated user array. |
| 2355 | | */ |
| 2356 | | $email_change_email = apply_filters( 'email_change_email', $email_change_email, $user, $userdata ); |
| | 2335 | /** |
| | 2336 | * Filters the contents of the email sent when the user's email is changed. |
| | 2337 | * |
| | 2338 | * @since 4.3.0 |
| | 2339 | * |
| | 2340 | * @param array $email_change_email { |
| | 2341 | * Used to build wp_mail(). |
| | 2342 | * |
| | 2343 | * @type string $to The intended recipients. |
| | 2344 | * @type string $subject The subject of the email. |
| | 2345 | * @type string $message The content of the email. |
| | 2346 | * The following strings have a special meaning and will get replaced dynamically: |
| | 2347 | * - ###USERNAME### The current user's username. |
| | 2348 | * - ###ADMIN_EMAIL### The admin email in case this was unexpected. |
| | 2349 | * - ###NEW_EMAIL### The new email address. |
| | 2350 | * - ###EMAIL### The old email address. |
| | 2351 | * - ###SITENAME### The name of the site. |
| | 2352 | * - ###SITEURL### The URL to the site. |
| | 2353 | * @type string $headers Headers. |
| | 2354 | * } |
| | 2355 | * @param array $user The original user array. |
| | 2356 | * @param array $userdata The updated user array. |
| | 2357 | */ |
| | 2358 | $email_change_email = apply_filters( 'email_change_email', $email_change_email, $user, $userdata ); |
| 2358 | | $email_change_email['message'] = str_replace( '###USERNAME###', $user['user_login'], $email_change_email['message'] ); |
| 2359 | | $email_change_email['message'] = str_replace( '###ADMIN_EMAIL###', get_option( 'admin_email' ), $email_change_email['message'] ); |
| 2360 | | $email_change_email['message'] = str_replace( '###NEW_EMAIL###', $userdata['user_email'], $email_change_email['message'] ); |
| 2361 | | $email_change_email['message'] = str_replace( '###EMAIL###', $user['user_email'], $email_change_email['message'] ); |
| 2362 | | $email_change_email['message'] = str_replace( '###SITENAME###', $blog_name, $email_change_email['message'] ); |
| 2363 | | $email_change_email['message'] = str_replace( '###SITEURL###', home_url(), $email_change_email['message'] ); |
| | 2360 | $email_change_email['message'] = str_replace( '###USERNAME###', $user['user_login'], $email_change_email['message'] ); |
| | 2361 | $email_change_email['message'] = str_replace( '###ADMIN_EMAIL###', get_option( 'admin_email' ), $email_change_email['message'] ); |
| | 2362 | $email_change_email['message'] = str_replace( '###NEW_EMAIL###', $userdata['user_email'], $email_change_email['message'] ); |
| | 2363 | $email_change_email['message'] = str_replace( '###EMAIL###', $user['user_email'], $email_change_email['message'] ); |
| | 2364 | $email_change_email['message'] = str_replace( '###SITENAME###', $blog_name, $email_change_email['message'] ); |
| | 2365 | $email_change_email['message'] = str_replace( '###SITEURL###', home_url(), $email_change_email['message'] ); |