untrashed_comment

動作鉤子
do_action( 'untrashed_comment', $comment->comment_ID, $comment )
引數
  • (string) $comment_id The comment ID as a numeric string.
    Required:
  • (WP_Comment) $comment The untrashed comment.
    Required:
定義位置
相關勾子
trashed_commentuntrash_commenttrash_commentunspammed_commentunspam_comment
相關方法
wp_untrash_commentthe_commentwp_trash_commentwp_untrash_post_commentsedit_commentwp_trash_post_comments
引入
4.9.0
棄用
-

“untrashed_comment”是一個動作鉤子,在從回收站中恢復評論後觸發。 當評論從回收站中恢復時,此鉤子可用於執行其他操作,例如傳送通知、更新其他記錄或記錄活動。

在評論從回收站中恢復後立即觸發。

Plain text
Copy to clipboard
Open code in new window
EnlighterJS 3 Syntax Highlighter
do_action( 'untrashed_comment', $comment->comment_ID, $comment );
do_action( 'untrashed_comment', $comment->comment_ID, $comment );
do_action( 'untrashed_comment', $comment->comment_ID, $comment );

常見問題

FAQs
檢視更多 >