duplicate_comment_id WordPress Filter Hook

The duplicate_comment_id hook is called when a comment is inserted into the database. If the comment already exists, the hook will return an error.

apply_filters( 'duplicate_comment_id', int $dupe_id, array $commentdata ) #

Filters the ID, if any, of the duplicate comment found when creating a new comment.


Description

Return an empty value from this filter to allow what WP considers a duplicate comment.


Top ↑

Parameters

$dupe_id

(int)ID of the comment identified as a duplicate.

$commentdata

(array)Data for the comment being created.


Top ↑

Source

File: wp-includes/comment.php

View on Trac



Top ↑

Changelog

Changelog
VersionDescription
4.4.0Introduced.

The content displayed on this page has been created in part by processing WordPress source code files which are made available under the GPLv2 (or a later version) license by theĀ Free Software Foundation. In addition to this, the content includes user-written examples and information. All material is subject to review and curation by the WPPaste.com community.

Show More
Show More