WPDev.one
Core Function
View Source on Trac ↗

wp_check_comment_data()

wp_check_comment_data( mixed $comment_data )

Checks whether comment data passes internal checks or has disallowed content.

Parameters 1 required

Name / Type Description
$comment_data
array

Array of arguments for inserting a comment.

Required

Return Value

((int)
(int | string | WP_Error) The approval status on success (0|1|'spam'|'trash'), WP_Error otherwise.

Function Information

Since Version
6.7.0
Source File
wp-includes/comment.php
Advertisement