WordPress.org

Ready to get started?Download WordPress

Codex

Attention Interested in functions, hooks, classes, or methods? Check out the new WordPress Code Reference!

Function Reference/wp throttle comment flood

Description

Determine whether comment should be blocked because of comment flood.

Usage

<?php wp_throttle_comment_flood$block$time_lastcomment$time_newcomment ?>

Parameters

$block
(boolean) (required) True if plugin is blocking comments.
Default: None
$time_lastcomment
(integer) (required) Timestamp for last comment.
Default: None
$time_newcomment
(integer) (required) Timestamp for new comment.
Default: None

Return Values

(boolean) 
Returns true if $block is true or if $block is false and $time_newcomment - $time_lastcomment < 15. Returns false otherwise.

Examples

Notes

Change Log

Since: 2.1.0

Source File

wp_throttle_comment_flood() is located in wp-includes/comment.php.

Related

 

See also index of Function Reference and index of Template Tags.