comment_reply_to_unapproved_comment
云策文档标注
概述
comment_reply_to_unapproved_comment 是一个 WordPress 动作钩子,在尝试回复未批准评论时触发。它主要用于处理评论提交流程中的特定场景。
关键要点
- 这是一个动作钩子,当用户尝试回复一个未批准的评论时触发。
- 钩子传递两个参数:$comment_post_id(文章ID)和$comment_parent(父评论ID)。
- 在 WordPress 6.2.0 版本中引入。
- 与 wp_handle_comment_submission() 函数相关,用于处理评论提交。
原文内容
Fires when a comment reply is attempted to an unapproved comment.
Parameters
$comment_post_idint-
Post ID.
$comment_parentint-
Parent comment ID.
Source
do_action( 'comment_reply_to_unapproved_comment', $comment_post_id, $comment_parent );
Changelog
| Version | Description |
|---|---|
| 6.2.0 | Introduced. |