I am attempting to create a function that will check the number of days left before an event (ACF field called ‘meeting_date’)
If the event is 4 or more days away, I want to be able to show a form for people to book.
If it’s 3 or less days before the event, then I want to show a notice that it’s too late to book.
The posts already expire on the day of the event, so we don’t need number of days since the event.
I’ve tried all sorts of variations of code on stack-exchange, stack-over-flow and also a few posts on here.
Has anyone done similar?
Thanks for sharing your solution, others might find it useful.