Forum

Thread tagged as: Question, Addons, Events

Events in the next 7 days

Hi, I'm new to the events app and it seems great but I'm just wondering how I'd go about returning all events in the next 7 days (including the current day)?

I figure I would use the filter, match, value but is there a way of using the match and value to automatically retrieve the current day plus 6?

Cheers

Simon Russell

Simon Russell 0 points

  • 4 years ago
Drew McLellan

Drew McLellan 2638 points
Perch Support

Today's date is:

date('Y-m-d H:i:s');

The date in 6 days time is:

date('Y-m-d H:i:s', strtotime('+6 DAYS'));

You can then use that in your filter.

PERFECT! Thanks Drew