PDA

View Full Version : is there anyway to find out how many times someone has clicked adoptables?


aroymart
04-11-2009, 07:49 PM
is there anyway to find out how many times someone has clicked adoptables throughout there entire time being signed up? if so a "shop" wouldn't be hard couldn't you just put something like

if ($clicks >= 100)
{
??????
}
[/php]
without having to access the mySQL, i can't access it myself

BMR777
04-11-2009, 08:00 PM
You could do:

$query = "SELECT * FROM vote_voters WHERE username = '$username'";
$result = mysql_query($query);
$num = mysql_numrows($result);

The number of times a user clicked on ANY adoptable EVER will be stored in $num. :)

Brandon

aroymart
04-11-2009, 08:14 PM
sweet so that means we can include badges,special adoptables,and unlockables! this is going to bring a whole new wave of scripts!!!!


how would i do this? like this?


if ($num <= 100)
{
echo "hello! congrats you have reached a break point <br> your prize is..............<br><br> a new adopt, email aroymart@yahoo.com to get the special adopt!"
}

BMR777
04-12-2009, 05:57 PM
Well, you have it if the number is less than or equal to 100, should be $num >= 100 instead, but yeah, just put your code between the if brackets. :)

aroymart
04-13-2009, 03:36 PM
whoops lol i was a little dizzy-late at night