PDA

View Full Version : Limit clicks/day to 10


sensacion
07-01-2011, 08:08 PM
hi guys, i want this: Limit clicks/day to 10
how I can insert the following code at the levelup.php
or you have another idea

$query = "SELECT * FROM ".$prefix."vote_voters WHERE adoptableid='$id' and date = '$date'";
$result = mysql_query($query);
$ctd = mysql_numrows($result);
if ($ctd > 99) { $article_title = "Error";
$article_content = "<font color='#cc1111'>This Pet has recieved the maximum of 100 clicks per day</font>"; }
else if ($ctd <= 99) {

// Add to clicks, levelup and text return

}

Chibi_Chicken
07-02-2011, 05:15 AM
you could add that code after it build the $date var. on page line 50.