diff --git a/src/wp-includes/comment-template.php b/src/wp-includes/comment-template.php index af375c533f..79b51c1a98 100644 --- a/src/wp-includes/comment-template.php +++ b/src/wp-includes/comment-template.php @@ -1881,6 +1881,7 @@ function wp_list_comments( $args = array(), $comments = null ) { * @since 3.0.0 * @since 4.1.0 Introduced the 'class_submit' argument. * @since 4.2.0 Introduced 'submit_button' and 'submit_fields' arguments. + * @since 4.4.0 Introduced 'title_reply_before' and 'title_reply_after' arguments. * * @param array $args { * Optional. Default arguments and form fields to override. @@ -1905,6 +1906,10 @@ function wp_list_comments( $args = array(), $comments = null ) { * @type string $title_reply The translatable 'reply' button label. Default 'Leave a Reply'. * @type string $title_reply_to The translatable 'reply-to' button label. Default 'Leave a Reply to %s', * where %s is the author of the comment being replied to. + * @type string $title_reply_before HTML displayed before the comment form title. + * Default: '

'. + * @type string $title_reply_after HTML displayed after the comment form title. + * Default: '

'. * @type string $cancel_reply_link The translatable 'cancel reply' button label. Default 'Cancel reply'. * @type string $label_submit The translatable 'submit' button label. Default 'Post a comment'. * @type string $submit_button HTML format for the Submit button. @@ -1966,6 +1971,8 @@ function comment_form( $args = array(), $post_id = null ) { 'name_submit' => 'submit', 'title_reply' => __( 'Leave a Reply' ), 'title_reply_to' => __( 'Leave a Reply to %s' ), + 'title_reply_before' => '

', + 'title_reply_after' => '

', 'cancel_reply_link' => __( 'Cancel reply' ), 'label_submit' => __( 'Post Comment' ), 'submit_button' => '', @@ -1997,7 +2004,20 @@ function comment_form( $args = array(), $post_id = null ) { do_action( 'comment_form_before' ); ?>
-

+ '; + + cancel_comment_reply_link( $args['cancel_reply_link'] ); + + echo ''; + + echo $args['title_reply_after']; + ?> +