Ticket #47004: 47004.patch
File 47004.patch, 8.6 KB (added by , 6 years ago) |
---|
-
wp-admin/includes/file.php
2376 2376 /** This filter is documented in wp-includes/functions.php */ 2377 2377 $expiration = apply_filters( 'wp_privacy_export_expiration', 3 * DAY_IN_SECONDS ); 2378 2378 $expiration_date = date_i18n( get_option( 'date_format' ), time() + $expiration ); 2379 $email_address = $request->email; 2380 $export_file_url = get_post_meta( $request_id, '_export_file_url', true ); 2381 $site_name = wp_specialchars_decode( get_option( 'blogname' ), ENT_QUOTES ); 2382 $site_url = home_url(); 2379 2383 2384 /* translators: Personal data export notification email subject. %s: Site title */ 2385 $subject = sprintf( __( '[%s] Personal Data Export' ), $site_name ); 2386 2380 2387 /* translators: Do not translate EXPIRATION, LINK, SITENAME, SITEURL: those are placeholders. */ 2381 2388 $email_text = __( 2382 2389 'Howdy, … … 2409 2416 */ 2410 2417 $content = apply_filters( 'wp_privacy_personal_data_email_content', $email_text, $request_id ); 2411 2418 2412 $email_address = $request->email;2413 $export_file_url = get_post_meta( $request_id, '_export_file_url', true );2414 $site_name = wp_specialchars_decode( get_option( 'blogname' ), ENT_QUOTES );2415 $site_url = home_url();2416 2417 2419 $content = str_replace( '###EXPIRATION###', $expiration_date, $content ); 2418 2420 $content = str_replace( '###LINK###', esc_url_raw( $export_file_url ), $content ); 2419 2421 $content = str_replace( '###EMAIL###', $email_address, $content ); … … 2420 2422 $content = str_replace( '###SITENAME###', $site_name, $content ); 2421 2423 $content = str_replace( '###SITEURL###', esc_url_raw( $site_url ), $content ); 2422 2424 2423 $mail_success = wp_mail( 2424 $email_address, 2425 sprintf( 2426 /* translators: Personal data export notification email subject. %s: Site title */ 2427 __( '[%s] Personal Data Export' ), 2428 $site_name 2429 ), 2430 $content 2431 ); 2425 $mail_success = wp_mail( $email_address, $subject, $content ); 2432 2426 2433 2427 if ( $switched_locale ) { 2434 2428 restore_previous_locale(); -
wp-admin/includes/misc.php
1239 1239 1240 1240 $switched_locale = switch_to_locale( get_user_locale() ); 1241 1241 1242 /* translators: New admin email address notification email subject. %s: Site title */ 1243 $subject = sprintf( __( '[%s] New Admin Email Address' ), wp_specialchars_decode( get_option( 'blogname' ), ENT_QUOTES ) ); 1244 1242 1245 /* translators: Do not translate USERNAME, ADMIN_URL, EMAIL, SITENAME, SITEURL: those are placeholders. */ 1243 1246 $email_text = __( 1244 1247 'Howdy ###USERNAME###, … … 1289 1292 $content = str_replace( '###SITENAME###', wp_specialchars_decode( get_option( 'blogname' ), ENT_QUOTES ), $content ); 1290 1293 $content = str_replace( '###SITEURL###', home_url(), $content ); 1291 1294 1292 /* translators: New admin email address notification email subject. %s: Site title */ 1293 wp_mail( $value, sprintf( __( '[%s] New Admin Email Address' ), wp_specialchars_decode( get_option( 'blogname' ), ENT_QUOTES ) ), $content ); 1295 wp_mail( $value, $subject, $content ); 1294 1296 1295 1297 if ( $switched_locale ) { 1296 1298 restore_previous_locale(); -
wp-admin/includes/upgrade.php
583 583 $email = $user->user_email; 584 584 $name = $user->user_login; 585 585 $login_url = wp_login_url(); 586 587 /* translators: New site notification email subject. %s: Site title */ 588 $subject = sprintf( __( '[%s] New WordPress Site' ), wp_specialchars_decode( get_option( 'blogname' ), ENT_QUOTES ) ); 589 586 590 /* translators: New site notification email. 1: New site URL, 2: User login, 3: User password or password reset link, 4: Login URL */ 587 591 $message = sprintf( 588 592 __( … … 608 612 $login_url 609 613 ); 610 614 611 @wp_mail( $email, __( 'New WordPress Site' ), $message );615 @wp_mail( $email, $subject, $message ); 612 616 } 613 617 endif; 614 618 -
wp-admin/ms-delete-site.php
46 46 47 47 $switched_locale = switch_to_locale( get_locale() ); 48 48 49 /* translators: Delete site confirmation notification email subject. %s: Site title */ 50 $subject = sprintf( __( '[%s] Delete My Site' ), wp_specialchars_decode( get_option( 'blogname' ), ENT_QUOTES ) ); 51 49 52 /* translators: Do not translate USERNAME, URL_DELETE, SITE_NAME: those are placeholders. */ 50 53 $content = __( 51 54 "Howdy ###USERNAME###, … … 78 81 $content = str_replace( '###URL_DELETE###', $url_delete, $content ); 79 82 $content = str_replace( '###SITE_NAME###', get_network()->site_name, $content ); 80 83 81 wp_mail( get_option( 'admin_email' ), '[ ' . wp_specialchars_decode( get_option( 'blogname' ) ) . ' ] ' . __( 'Delete My Site' ), $content );84 wp_mail( get_option( 'admin_email' ), $subject, $content ); 82 85 83 86 if ( $switched_locale ) { 84 87 restore_previous_locale(); -
wp-admin/user-new.php
112 112 113 113 $switched_locale = switch_to_locale( get_user_locale( $user_details ) ); 114 114 115 /* translators: Joining confirmation notification email subject. %s: Site title */ 116 $subject = sprintf( __( '[%s] Joining Confirmation' ), wp_specialchars_decode( get_option( 'blogname' ), ENT_QUOTES ) ); 117 115 118 /* translators: 1: Site name, 2: site URL, 3: role, 4: activation URL */ 116 119 $message = __( 117 120 'Hi, … … 123 126 %4$s' 124 127 ); 125 128 126 /* translators: Joining confirmation notification email subject. %s: Site title */ 127 wp_mail( $new_user_email, sprintf( __( '[%s] Joining Confirmation' ), wp_specialchars_decode( get_option( 'blogname' ) ) ), sprintf( $message, get_option( 'blogname' ), home_url(), wp_specialchars_decode( translate_user_role( $role['name'] ) ), home_url( "/newbloguser/$newuser_key/" ) ) ); 129 wp_mail( $new_user_email, $subject, sprintf( $message, get_option( 'blogname' ), home_url(), wp_specialchars_decode( translate_user_role( $role['name'] ) ), home_url( "/newbloguser/$newuser_key/" ) ) ); 128 130 129 131 if ( $switched_locale ) { 130 132 restore_previous_locale(); -
wp-includes/ms-functions.php
2596 2596 2597 2597 $switched_locale = switch_to_locale( get_user_locale() ); 2598 2598 2599 /* translators: Email change notification email subject. %s: Network title */ 2600 $subject = sprintf( __( '[%s] Network Admin Email Change Request' ), wp_specialchars_decode( get_site_option( 'site_name' ), ENT_QUOTES ) ); 2601 2599 2602 /* translators: Do not translate USERNAME, ADMIN_URL, EMAIL, SITENAME, SITEURL: those are placeholders. */ 2600 2603 $email_text = __( 2601 2604 'Howdy ###USERNAME###, … … 2645 2648 $content = str_replace( '###SITENAME###', wp_specialchars_decode( get_site_option( 'site_name' ), ENT_QUOTES ), $content ); 2646 2649 $content = str_replace( '###SITEURL###', network_home_url(), $content ); 2647 2650 2648 /* translators: Email change notification email subject. %s: Network title */ 2649 wp_mail( $value, sprintf( __( '[%s] Network Admin Email Change Request' ), wp_specialchars_decode( get_site_option( 'site_name' ), ENT_QUOTES ) ), $content ); 2651 wp_mail( $value, $subject, $content ); 2650 2652 2651 2653 if ( $switched_locale ) { 2652 2654 restore_previous_locale(); -
wp-includes/user.php
2761 2761 2762 2762 $sitename = wp_specialchars_decode( get_option( 'blogname' ), ENT_QUOTES ); 2763 2763 2764 /* translators: Email change request notification email subject. %s: Site name */ 2765 $subject = sprintf( __( '[%s] Email Change Request' ), $sitename ); 2766 2764 2767 /* translators: Do not translate USERNAME, ADMIN_URL, EMAIL, SITENAME, SITEURL: those are placeholders. */ 2765 2768 $email_text = __( 2766 2769 'Howdy ###USERNAME###, … … 2809 2812 $content = str_replace( '###SITENAME###', $sitename, $content ); 2810 2813 $content = str_replace( '###SITEURL###', home_url(), $content ); 2811 2814 2812 /* translators: New email address notification email subject. %s: Site name */ 2813 wp_mail( $_POST['email'], sprintf( __( '[%s] Email Change Request' ), $sitename ), $content ); 2815 wp_mail( $_POST['email'], $subject, $content ); 2814 2816 2815 2817 $_POST['email'] = $current_user->user_email; 2816 2818 }