在当天的某些部分删除数据库中的条目

So, I am building a website where people can search for places and check in to those places. I want every entry deleted (or altered) when users day ends.

For example, my time is 20:00 and I submit a check in. I want it deleted in 00:00. Also, some other users time is 22:00 for example, I want his deleted in 00:00, but not 00:00 in my time, but his.

I hope I clarified the problem, I gave my best. Is there even a way to do this or not?

mhhh the question is whether you have the right to run cronjobs. If it is the case that you can run cronjobs i would create a time zone entry in you're mysql db.

And see if the timestamps in the db for the user are equal to the current timme stamp (example using utc timestamps). And delete the entry if this is applicable

Here's the gist of how i would implement it In a rudementery form.

timestamp current

date_default_timezone_set('UTC');
$now = new DateTime();
echo $now->getTimestamp(); //Unix timme stamp

mysql

DELETE FROM table
WHERE timestamp <= $now

after delete

you can set the new utc time stamp of the next day

$value="00:00:00"; //just as an example use time zone from mysql table 
$timeStamp = strtotime('tomorrow ' .$value);

/*insert into mysql table structure*/

as for the crone job that is supposed to execute hourly

0 * * * * fille.php

I hope this met you're expectations.I gave my best too ;).