i've been looking around for a way to do this; I found one tutorial that suggested using the dateadd (which i found out is date_add in mysql) function... but I've had no luck with that.
I need to have something that updates the database every 15 minutes or so via a Cronjob... The cron job is already set up (Php file), but i cannot get the DB to update every fifteen minutes.
anyway, this is the code i've got currently--i was really stressing out trying to figure out how to get it to work... so i know what i'm doing doesn't actually work.
UPDATE starinformation SET starOwner = nextOwner, death = 'off', wifi = 'on' WHERE underSiege = 1 AND siegeStart = (current_timestamp)-15
I've also tried doing this
$date=date('-15 minutes'); $sql = "UPDATE starinformation SET starOwner = nextOwner, death = 'off', wifi = 'on' WHERE underSiege = 1 AND siegeStart = ".$date