E
E
emeresel2021-03-28 00:13:10
Content
emeresel, 2021-03-28 00:13:10

How to replace the output of a comment excerpt (get_comment_excerpt) with a full comment?

This function displays an excerpt of a comment up to 20 words, how can I replace it with a full comment? I will be grateful for your help!

if ( $attributes['displayExcerpt'] ) {
        $list_items_markup .= '<div class="wp-block-latest-comments__comment-excerpt">' . wpautop( get_comment_excerpt( $comment ) ) . '</div>';
      }
if ( $attributes['displayExcerpt'] ) {
    $classnames[] = 'has-excerpts';
  }

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question