LazyCron by Ryan Cramer

This core module provides hooks that are automatically executed at various intervals. This module is already included with the ProcessWire core, but not installed by default.

This core module provides hooks that are automatically executed at various intervals. This module is already included with the ProcessWire core, but not installed by default.

It is called 'lazy' because it's triggered by a pageview, so the interval is guaranteed to be at least the time requested (and maybe more) rather than exactly the time requested. The more pageviews your site gets, the closer it is. This is fine for most cases, but if you need it to be fully accurate I'll describe how you can make it not-lazy a little further down.

Hookable time intervals
------------
These are the function names you can hook from LazyCron. The function names describe the time intervals they provide. If you think I'm missing any important time intervals, please let us know and we can add more.


  • every30Seconds
  • everyMinute
  • every2Minutes
  • every3Minutes
  • every4Minutes
  • every5Minutes
  • every10Minutes
  • every15Minutes
  • every30Minutes
  • every45Minutes
  • everyHour
  • every2Hours
  • every4Hours
  • every6Hours
  • every12Hours
  • everyDay
  • every2Days
  • every4Days
  • everyWeek
  • every2Weeks
  • every4Weeks

Install and use modules at your own risk. Always have a site and database backup before installing new modules.

Latest news

  • ProcessWire Weekly #519
    In the 519th issue of ProcessWire Weekly we'll check out a new third party module called RockForms, introduce the latest ProcessWire core updates, and more. Read on!
    Weekly.pw / 20 April 2024
  • ProFields Table Field with Actions support
    This week we have some updates for the ProFields table field (FieldtypeTable). These updates are primarily focused on adding new tools for the editor to facilitate input and management of content in a table field.
    Blog / 12 April 2024
  • Subscribe to weekly ProcessWire news

“I am currently managing a ProcessWire site with 2 million+ pages. It’s admirably fast, and much, much faster than any other CMS we tested.” —Nickie, Web developer