• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[Solved] Delete row if key code is there for more than 15 min

#9
Another way would be this:

PHP Code:
$dt = new Datetime();   //create object for current date/time
$dt->modify('15 minutes ago');   //substract 15 minutes
$sdt $dt->format('Y-m-d H:i:s');  //format it into a datetime string

$this->db->where('date_modified <' $sdt); 
Reply


Messages In This Thread
RE: [Solved] Delete row if key code is there for more than 15 min - by Wouter60 - 02-07-2017, 02:35 PM

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2020 MyBB Group.