Ok bro, there's a real simple way of doing this, that's to add a little script within your own comment script that checks the IP of the last poster, that way prevents multiple comments
first if you made the comment script, you have to make sure your comment table has an IP field if it doesn't, you will need to add it. Log in to your PHPMyAdmin and open your comments table, run this query:
Code:
ALTER TABLE table ADD ip VARCHAR(20)
You have to combine the below script with your comment script
PHP Code:
<?php
// Database connection here
$query="SELECT * FROM table where ip='$ip' and date > CURDATE() - INTERVAL 5 MINUTE ";
$result= mysql_query($query) or die ("Could not execute query : $query." . mysql_error());
if (mysql_num_rows($result) == '0') {
// Insert your comments adding query and everything else here
} else {
echo "You're not allowed to post so soon after your last comment.";
}
?>
That's it really, oh and change
table with your actual table name and
date, if your date field has another name.
Like i said ff you didn't have an ip field before, you will need to edit your comments adding query and add the IP thing. You will need to edit your comments form too, add this:
Code:
<input type="hidden" name="ip" value="<?php $visitorip = $_SERVER['REMOTE_ADDR'];
echo "$visitorip"; ?>" />
Kareem, if you're still confused and shit try what you can and post some feed back here bro.