diff --git a/src/wp-includes/comment-template.php b/src/wp-includes/comment-template.php index 76a0ee0ff9..026498821e 100644 --- a/src/wp-includes/comment-template.php +++ b/src/wp-includes/comment-template.php @@ -1305,13 +1305,14 @@ function comments_popup_link( $zero = false, $one = false, $more = false, $css_c function get_comment_reply_link( $args = array(), $comment = null, $post = null ) { $defaults = array( - 'add_below' => 'comment', - 'respond_id' => 'respond', - 'reply_text' => __('Reply'), - 'login_text' => __('Log in to Reply'), - 'depth' => 0, - 'before' => '', - 'after' => '' + 'add_below' => 'comment', + 'respond_id' => 'respond', + 'reply_text' => __( 'Reply' ), + 'reply_to_text' => __( 'Reply to %s' ), + 'login_text' => __( 'Log in to Reply' ), + 'depth' => 0, + 'before' => '', + 'after' => '' ); $args = wp_parse_args( $args, $defaults ); @@ -1337,7 +1338,7 @@ function get_comment_reply_link( $args = array(), $comment = null, $post = null if ( get_option( 'comment_registration' ) && ! is_user_logged_in() ) { $link = '' . $args['login_text'] . ''; } else { - $link = "comment_ID ) ) . "#" . $respond_id . "' onclick='return addComment.moveForm(\"$add_below-$comment->comment_ID\", \"$comment->comment_ID\", \"$respond_id\", \"$post->ID\")'>$reply_text"; + $link = "comment_ID ) ) . "#" . $respond_id . "' onclick='return addComment.moveForm(\"$add_below-$comment->comment_ID\", \"$comment->comment_ID\", \"$respond_id\", \"$post->ID\")' aria-label='" . esc_attr( sprintf( $args['reply_to_text'], $comment->comment_author ) ) . "'>$reply_text"; } /** * Filter the comment reply link.