pre_comment_on_post

pre_comment_on_post

Appears in: , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
Hook Type: action
See hook in action

See hook in core

Displaying hooks found in version: wordpress-6.4.3

do_action('pre_comment_on_post') is found 1 times:

  • /wp-includes/comment.php line 3598
    		 * @since 2.8.0
    		 *
    		 * @param int $comment_post_id Post ID.
    		 */
    		do_action( 'pre_comment_on_post', $comment_post_id );
    	}
    
    	// If the user is logged in.
    	$user = wp_get_current_user();
    	if ( $user->exists() ) {
    		if ( empty( $user->display_name ) ) {
    

See this hook used in plugins: