I am creating a small plugin get get's data from different websites. The data does not have to be up to date, and I do not want to use a cronjob for this.
Instead with every visit of the website I want to check if the DB needs updating. Now it takes a while before the whole db is updated, and I do not want the user waiting for that.
Is there a way that I can have the function fired, but in the background. The user will just work as normal, but in the background the db is updating.