comment_atom_entry
云策文档标注
概述
comment_atom_entry 是一个 WordPress 动作钩子,在每个 Atom 评论源项目结束时触发,用于执行自定义操作。
关键要点
- 触发时机:在每个 Atom 评论源项目结束时执行。
- 参数:$comment_id(当前评论的 ID)和 $comment_post_id(当前评论关联的文章 ID)。
- 版本历史:自 WordPress 2.2.0 版本引入。
代码示例
do_action( 'comment_atom_entry', $comment->comment_ID, $comment_post->ID );
原文内容
Fires at the end of each Atom comment feed item.
Parameters
$comment_idint-
ID of the current comment.
$comment_post_idint-
ID of the post the current comment is connected to.
Source
do_action( 'comment_atom_entry', $comment->comment_ID, $comment_post->ID );
Changelog
| Version | Description |
|---|---|
| 2.2.0 | Introduced. |