开发者

Wordpress Plugin, capture comment insertion

is there a hook to capture the moment a comment is inserted int开发者_开发百科o a post?

In wordpress docs, they say that 'edit_post' works because the comment count on that post is updated, but it doesn't work.

Thanks


There's an action hook called "wp_insert_comment" that's called from wp_insert_comment(). It passes the comment id and the new comment as an object. (wp-includes/comment.php on line 1245.)

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜