diff --git a/src/wp-admin/includes/media.php b/src/wp-admin/includes/media.php
index c941e62..00ed504 100644
a
|
b
|
function media_buttons( $editor_id = 'content' ) { |
620 | 620 | * |
621 | 621 | * @param string $string Media buttons context. Default empty. |
622 | 622 | */ |
623 | | $legacy_filter = apply_filters( 'media_buttons_context', '' ); |
| 623 | $legacy_filter = apply_filters_deprecated( 'media_buttons_context', array(), '3.5.0', false, __( 'Please use "media_buttons" action instead.' ) ); |
624 | 624 | |
625 | 625 | if ( $legacy_filter ) { |
626 | 626 | // #WP22559. Close <a> if a plugin started by closing <a> to open their own <a> tag. |
diff --git a/src/wp-admin/privacy.php b/src/wp-admin/privacy.php
index 9c360dd..b9c5d8c 100644
a
|
b
|
require_once( ABSPATH . 'wp-admin/admin-header.php' ); |
155 | 155 | <p class="tools-privacy-edit"><strong> |
156 | 156 | <?php |
157 | 157 | |
158 | | /* translators: 1: URL to edit page, 2: URL to view page */ |
159 | | printf( __( '<a href="%1$s">Edit</a> or <a href="%2$s">view</a> your privacy policy page content.' ), $edit_href, $view_href ); |
| 158 | if ( 'publish' === get_post_status( $privacy_policy_page_id ) ) { |
| 159 | /* translators: 1: URL to edit page, 2: URL to view page */ |
| 160 | printf( __( '<a href="%1$s">Edit</a> or <a href="%2$s">view</a> your privacy policy page content.' ), $edit_href, $view_href ); |
| 161 | } else { |
| 162 | /* translators: 1: URL to edit page, 2: URL to preview page */ |
| 163 | printf( __( '<a href="%1$s">Edit</a> or <a href="%2$s">preview</a> your privacy policy page content.' ), $edit_href, $view_href ); |
| 164 | } |
160 | 165 | |
161 | 166 | ?> |
162 | 167 | </strong></p> |
diff --git a/src/wp-includes/comment-template.php b/src/wp-includes/comment-template.php
index f7626f5..649f29a 100644
a
|
b
|
function comment_form( $args = array(), $post_id = null ) { |
2262 | 2262 | $req = get_option( 'require_name_email' ); |
2263 | 2263 | $html_req = ( $req ? " required='required'" : '' ); |
2264 | 2264 | $html5 = 'html5' === $args['format']; |
2265 | | $consent = empty( $commenter['comment_author_email'] ) ? '' : ' checked="checked"'; |
2266 | 2265 | $fields = array( |
2267 | 2266 | 'author' => '<p class="comment-form-author">' . '<label for="author">' . __( 'Name' ) . ( $req ? ' <span class="required">*</span>' : '' ) . '</label> ' . |
2268 | 2267 | '<input id="author" name="author" type="text" value="' . esc_attr( $commenter['comment_author'] ) . '" size="30" maxlength="245"' . $html_req . ' /></p>', |
… |
… |
function comment_form( $args = array(), $post_id = null ) { |
2270 | 2269 | '<input id="email" name="email" ' . ( $html5 ? 'type="email"' : 'type="text"' ) . ' value="' . esc_attr( $commenter['comment_author_email'] ) . '" size="30" maxlength="100" aria-describedby="email-notes"' . $html_req . ' /></p>', |
2271 | 2270 | 'url' => '<p class="comment-form-url"><label for="url">' . __( 'Website' ) . '</label> ' . |
2272 | 2271 | '<input id="url" name="url" ' . ( $html5 ? 'type="url"' : 'type="text"' ) . ' value="' . esc_attr( $commenter['comment_author_url'] ) . '" size="30" maxlength="200" /></p>', |
2273 | | 'cookies' => '<p class="comment-form-cookies-consent"><input id="wp-comment-cookies-consent" name="wp-comment-cookies-consent" type="checkbox" value="yes"' . $consent . ' />' . |
2274 | | '<label for="wp-comment-cookies-consent">' . __( 'Save my name, email, and website in this browser for the next time I comment.' ) . '</label></p>', |
2275 | 2272 | ); |
2276 | 2273 | |
| 2274 | if ( has_action( 'set_comment_cookies', 'wp_set_comment_cookies' ) ) { |
| 2275 | $consent = empty( $commenter['comment_author_email'] ) ? '' : ' checked="checked"'; |
| 2276 | $fields['cookies'] = '<p class="comment-form-cookies-consent"><input id="wp-comment-cookies-consent" name="wp-comment-cookies-consent" type="checkbox" value="yes"' . $consent . ' />' . |
| 2277 | '<label for="wp-comment-cookies-consent">' . __( 'Save my name, email, and website in this browser for the next time I comment.' ) . '</label></p>'; |
| 2278 | } |
| 2279 | |
2277 | 2280 | $required_text = sprintf( ' ' . __( 'Required fields are marked %s' ), '<span class="required">*</span>' ); |
2278 | 2281 | |
2279 | 2282 | /** |
diff --git a/src/wp-includes/user.php b/src/wp-includes/user.php
index 73c3f3c..3d940e1 100644
a
|
b
|
function _wp_privacy_send_request_confirmation_notification( $request_id ) { |
2973 | 2973 | return; |
2974 | 2974 | } |
2975 | 2975 | |
2976 | | $subject = sprintf( |
2977 | | /* translators: %s Site name. */ |
2978 | | __( '[%s] Action Confirmed' ), |
2979 | | wp_specialchars_decode( get_option( 'blogname' ), ENT_QUOTES ) |
2980 | | ); |
2981 | | |
2982 | 2976 | $manage_url = add_query_arg( 'page', $request_data->action_name, admin_url( 'tools.php' ) ); |
2983 | 2977 | |
2984 | 2978 | /** |
… |
… |
All at ###SITENAME### |
3049 | 3043 | * @type string $manage_url The link to click manage privacy requests of this type. |
3050 | 3044 | * @type string $sitename The site name sending the mail. |
3051 | 3045 | * @type string $siteurl The site URL sending the mail. |
| 3046 | * @type string $admin_email The administrator email receiving the mail. |
3052 | 3047 | * } |
3053 | 3048 | */ |
3054 | 3049 | $content = apply_filters( 'user_confirmed_action_email_content', $email_text, $email_data ); |
… |
… |
All at ###SITENAME### |
3059 | 3054 | $content = str_replace( '###MANAGE_URL###', esc_url_raw( $email_data['manage_url'] ), $content ); |
3060 | 3055 | $content = str_replace( '###SITEURL###', esc_url_raw( $email_data['siteurl'] ), $content ); |
3061 | 3056 | |
| 3057 | $blogname = wp_specialchars_decode( get_option( 'blogname' ), ENT_QUOTES ); |
| 3058 | |
| 3059 | $subject = sprintf( |
| 3060 | /* translators: %s Site name. */ |
| 3061 | __( '[%s] Action Confirmed' ), |
| 3062 | $blogname |
| 3063 | ); |
| 3064 | |
| 3065 | /** |
| 3066 | * Filters the subject of the user request confirmation email. |
| 3067 | * |
| 3068 | * @since 4.9.7 |
| 3069 | * |
| 3070 | * @param string $subject The email subject. |
| 3071 | * @param string $blogname The name of the site. |
| 3072 | * @param array $email_data { |
| 3073 | * Data relating to the account action email. |
| 3074 | * |
| 3075 | * @type WP_User_Request $request User request object. |
| 3076 | * @type string $user_email The email address confirming a request |
| 3077 | * @type string $description Description of the action being performed so the user knows what the email is for. |
| 3078 | * @type string $manage_url The link to click manage privacy requests of this type. |
| 3079 | * @type string $sitename The site name sending the mail. |
| 3080 | * @type string $siteurl The site URL sending the mail. |
| 3081 | * @type string $admin_email The administrator email receiving the mail. |
| 3082 | * } |
| 3083 | */ |
| 3084 | $subject = apply_filters( 'user_request_confirmed_email_subject', $subject, $blogname, $email_data ); |
| 3085 | |
3062 | 3086 | $email_sent = wp_mail( $email_data['admin_email'], $subject, $content ); |
3063 | 3087 | |
3064 | 3088 | if ( $email_sent ) { |
diff --git a/tests/phpunit/tests/comment.php b/tests/phpunit/tests/comment.php
index 7f63c62..a1e3fb3 100644
a
|
b
|
class Tests_Comment extends WP_UnitTestCase { |
1156 | 1156 | $this->assertSame( $expected['comment_agent'], $actual['data'][0]['data'][4]['value'] ); |
1157 | 1157 | $this->assertSame( $expected['comment_date'], $actual['data'][0]['data'][5]['value'] ); |
1158 | 1158 | $this->assertSame( $expected['comment_content'], $actual['data'][0]['data'][6]['value'] ); |
1159 | | $this->assertSame( get_comment_link( $comment_id ), strip_tags( $actual['data'][0]['data'][7]['value'] ) ); |
| 1159 | $this->assertSame( esc_html( get_comment_link( $comment_id ) ), strip_tags( $actual['data'][0]['data'][7]['value'] ) ); |
1160 | 1160 | } |
1161 | 1161 | |
1162 | 1162 | /** |