Title: posting the same comment
Last modified: August 19, 2016

---

# posting the same comment

 *  [gramercy](https://wordpress.org/support/users/gramercy/)
 * (@gramercy)
 * [18 years, 3 months ago](https://wordpress.org/support/topic/posting-the-same-comment/)
 * when the
    – same user or – same visitor & e-mail
 * sends the
    – exact same comment or – even just similar content in the comment
   field (particularly with special characters)
 * the system gives an error
    **“You’ve said that before. No need to repeat yourself”**
 * maybe im dumber than a doorknob, but i didn’t find the problem or the solution
   anywhere, even though im guessing this is a frequent problem
 * any solution, anyone? thx!!!

Viewing 6 replies - 1 through 6 (of 6 total)

 *  Thread Starter [gramercy](https://wordpress.org/support/users/gramercy/)
 * (@gramercy)
 * [18 years, 3 months ago](https://wordpress.org/support/topic/posting-the-same-comment/#post-690464)
 * a similar error on a different blog
    **“Duplicate comment detected; it looks 
   as though you’ve already said that!”**
 *  [whooami](https://wordpress.org/support/users/whooami/)
 * (@whooami)
 * [18 years, 3 months ago](https://wordpress.org/support/topic/posting-the-same-comment/#post-690471)
 * _“You’ve said that before. No need to repeat yourself”_ is not a WordPress message.
   Thats a plugin spitting that out. So, if you see it, look at your plugins.
 * _
    “Duplicate comment detected; it looks as though you’ve already said that!”
   **
   IS** a wordpress message. If you want to tweek that crack open comment.php and
   look for the function `wp\_allow\_comment($commentdata)`
 * within that function, you will find:
 *     ```
       // Simple duplicate check
       	$dupe = "SELECT comment_ID FROM $wpdb->comments WHERE comment_post_ID = '$comment_post_ID' AND ( comment_author = '$comment_author' ";
       	if ( $comment_author_email )
       		$dupe .= "OR comment_author_email = '$comment_author_email' ";
       	$dupe .= ") AND comment_content = '$comment_content' LIMIT 1";
       	if ( $wpdb->get_var($dupe) )
       		wp_die( __('Duplicate comment detected; it looks as though you\'ve already said that!') );
       ```
   
 *  Thread Starter [gramercy](https://wordpress.org/support/users/gramercy/)
 * (@gramercy)
 * [18 years, 3 months ago](https://wordpress.org/support/topic/posting-the-same-comment/#post-690476)
 * ok, so just out of curiosity, if i delete/disable that ‘duplicate check’ bit 
   in comment.php, will that solve it without screwing up other stuff in WP?
 * thx!
 *  Thread Starter [gramercy](https://wordpress.org/support/users/gramercy/)
 * (@gramercy)
 * [18 years, 3 months ago](https://wordpress.org/support/topic/posting-the-same-comment/#post-690482)
 * also, is there a particular reason for this? i mean other than a lame way of 
   stopping spam?
 *  [whooami](https://wordpress.org/support/users/whooami/)
 * (@whooami)
 * [18 years, 3 months ago](https://wordpress.org/support/topic/posting-the-same-comment/#post-690484)
 * I dont have a clue about either of your questions. Why not just do it and see.
 *  [damienk](https://wordpress.org/support/users/damienk/)
 * (@damienk)
 * [17 years, 7 months ago](https://wordpress.org/support/topic/posting-the-same-comment/#post-690840)
 * I was having the same problem, and for anyone still wondering, here’s how you
   fix it:
 * In the “`wp-includes`” folder, locate the file “`comment.php`” and open this 
   with a text editor. (ie: Notepad or TextEdit) Do a quick find (Edit > Find) for
   the word `duplicate` and you’ll arrive at these lines of code.
 *     ```
       // Simple duplicate check
       	 expected_slashed ($comment_post_ID, $comment_author, $comment_author_email, $comment_content)
       	$dupe = "SELECT comment_ID FROM $wpdb->comments WHERE comment_post_ID = '$comment_post_ID' AND ( comment_author = '$comment_author' ";
       	if ( $comment_author_email )
       		$dupe .= "OR comment_author_email = '$comment_author_email' ";
       	$dupe .= ") AND comment_content = '$comment_content' LIMIT 1";
       	if ( $wpdb->get_var($dupe) )
       		wp_die( __('Duplicate comment detected; it looks as though you\'ve already said that!') );
       ```
   
 * You can delete this code completely or mark it as comments with two forward slashes
   at the beginning of each line `//`
 * Delete it if you never want to see it again, and comment it if you wish to keep
   it for a later use.
 * Once complete, save it and upload it to the appropriate location on your web 
   server.
 * Ta da! Go post the same comment twice, no one cares any more.
 * Please note that future upgrades to WordPress may very well overwrite your comments.
   php that you just edited, and you may need to do this again.

Viewing 6 replies - 1 through 6 (of 6 total)

The topic ‘posting the same comment’ is closed to new replies.

## Tags

 * [comment](https://wordpress.org/support/topic-tag/comment/)
 * [problem](https://wordpress.org/support/topic-tag/problem/)
 * [same](https://wordpress.org/support/topic-tag/same/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 6 replies
 * 3 participants
 * Last reply from: [damienk](https://wordpress.org/support/users/damienk/)
 * Last activity: [17 years, 7 months ago](https://wordpress.org/support/topic/posting-the-same-comment/#post-690840)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
