how to use a date module within a cron to send out 2 day, 7day, 30day messages?
Posted on 2004-04-08
I'm writing a script that sends out remindermessages 2days, 7days, and 30days after a customer signs up with my services.
I currently log all orders in a log file... I'm able to retrieve the date/email from the log file.... and I'm able to send people email messgaes just fine in my script. The problem is that I have no idea how to use a date function to determine which customers need to be sent a message. I assume it is probably like 5 lines of code if any one here is familiar with a date module.
So for example:
Today is April 1st. Therefore I run the cron at 1am on April 1st. I have a client that signed up on March 30th. (2 days ago). How do I go about determining, that this customer needs to be sent an email? The variable I use for the day the client signed up is $signupdate . $signupdate is in this format: 4-1-2004
Any help would be much appreciated.