trashed_comment

动作钩子
do_action( 'trashed_comment', $comment->comment_ID, $comment )
参数
  • (string) $comment_id The comment ID as a numeric string.
    Required:
  • (WP_Comment) $comment The trashed comment.
    Required:
定义位置
相关勾子
untrashed_commenttrash_commentuntrash_commentedit_commentdeleted_comment
相关方法
the_commentwp_trash_commentwp_untrash_commentedit_commenthave_commentscheck_comment
引入
4.9.0
弃用
-

trashed_comment – 这是一个WordPress的动作,当一个评论被移到垃圾桶时被触发。trashed_comment动作是在评论刚刚被移到垃圾桶后触发的,可以用来执行额外的动作,比如发送电子邮件通知或更新其他数据。

在评论被送入回收站后立即触发。

do_action( 'trashed_comment', $comment->comment_ID, $comment );

常见问题

FAQs
查看更多 >
闪电侠

(工作日 10:00 - 18:30 为您服务)

2025-12-05 19:32:59

您好,无论是售前、售后、意见建议……均可通过联系工单与我们取得联系。

您也可选择聊天工具与我们即时沟通或点击查看:

您的工单我们已经收到,我们将会尽快跟您联系!
取消
选择聊天工具: