VitalEnd Posted October 10, 2010 Share Posted October 10, 2010 Ok i couldn't get the function to work so i just wrote a query ... only problem is nothing is inserting into the table and i think its down to the SELECT query, if someone could point out the error or write it up correctly for me it would be most appreciated, thanks $winner=$db->query("SELECT * FROM users WHERE rampageKILLS > 0 ORDER BY rampageKILLS DESC LIMIT 1"); while($w=$db->fetch_row($winner)) { $db->query("INSERT INTO events VALUES('',{$w['userid']},unix_timestamp(),0,'text here')"); } Quote Link to comment Share on other sites More sharing options...
Djkanna Posted October 11, 2010 Share Posted October 11, 2010 Well event_add will work if you include global_func.php otherwise event_add doesn't exist. Quote Link to comment Share on other sites More sharing options...
Dominion Posted October 11, 2010 Share Posted October 11, 2010 just add event_add() into the cron file, saves you having to include the global_func.php file. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.