XF 2.2 cronjob for the last 100 threads

Robert9

Well-known member
I have viewed many cron-jobs now,
but i can not find an example how to do a batch for all threads or the last 100 by thread_id or last_post_id.
Do we have an add-on to see an example how to do?

The job for this is done; now I need a cron doing the same automatically.
 
Maybe it is not possible just to do this without saving a thread_id for example?

Call cronjob, check if there is a saved thread_id, else get lowest id, do something, save the id.
Call cronjob, get saved thread_id, if saved, get next thread, do something, save_id, else if there is no higher id, delete saved id
...

combinated with a date; this could run dayly one time until finished?

I have no idea where to save an id and a date, but I guess there should be a million examples in the code.
 
Back
Top Bottom