当前浏览:首页 / WordPress函数 / comment_excerpt()

comment_excerpt( int|WP_Comment $comment_ID )

显示当前评论的摘录

comment 评论more...

excerpt 摘要more...


参数

$comment_ID

(int|WP_Comment)(必填) WP_Comment或要打印摘录的评论的ID。默认当前评论。



源码

查看源码 官方文档


更新日志

版本描述
4.4.0增加了$comment_ID也能接受WP_Comment对象的能力。
1.2.0开始引入

使用示例

  • 示例1

    实例

    <p>Latest comment: <?php comment_excerpt(); ?></p>