wp_insert_comment хук-событие . WP 2.8.0
Fires immediately after a comment is inserted into the database.
Использование
add_action( 'wp_insert_comment', 'action_function_name_3619', 10, 2 ); function action_function_name_3619( $id, $comment ){ // action... }
- $id(число)
- The comment ID.
- $comment(WP_Comment)
- Comment object.
Список изменений
С версии 2.8.0 | Введена. |
Где вызывается хук
wp_insert_comment
wp-includes/comment.php 2047
do_action( 'wp_insert_comment', $id, $comment );