I'm trying to use strtotime() to respond to a button click to advance -1 and +1 days (two buttons) relative to the day advanced to on the previous click.
Example: It's the 10th of the month, I click "-1 day" button, and now the date reads as the 9th. I click the "-1 day" button again and now the readout states the 8th day. I click the "+1 day" button and now the readout states it's the 9th.
I understand the buttons and the displaying the date, and using $_GET and php to pass info, but how do I get strtotime() to work on the relative date from the last time the time travel script was called.
My work so far has let me show yesterday and today relative to now but not relative to, for example, the day before yesterday, or the day after tomorrow. Or if I use my "last monday" button, the day before or after whatever that day is.