Filters a comment’s data before it is sanitized and inserted into the database.
Parameters
$commentdata
array- Comment data.
Source
$commentdata = apply_filters( 'preprocess_comment', $commentdata );
Filters a comment’s data before it is sanitized and inserted into the database.
$commentdata
array$commentdata = apply_filters( 'preprocess_comment', $commentdata );
You must log in before being able to contribute a note or feedback.
Example migrated from Codex:
The example below remove the URL from the comment author text (comment_author_url) and changes the first character of each word of the comment content to upper case if it’s in all upper case.