显示用于回复评论链接的HTML内容。
原型
comment_reply_link( array $args = array(), int $comment = null, int|WP_Post $post = null )
参数
$args
(array)
(Optional)
覆盖默认选项。
$comment
(int)
(Optional)
评论被回复。默认当前评论。
$post
(int|WP_Post)
(Optional)
帖子ID或WP_Post对象将显示评论。默认当前帖子。
返回值
(mixed)
如果成功,请链接以显示评论表单。如果评论已关闭,则为false。
源文件
路径:wp-includes/comment-template.php
<?php
...
function comment_reply_link($args = array(), $comment = null, $post = null) {
echo get_comment_reply_link($args, $comment, $post);
}
...
?>
其他
英文文档:https://developer.wordpress.org/reference/functions/comment_reply_link/