Ross Clutterbuck wrote:
The client would rather not rely on the users' memory to do these
reports and would like a reminder e-mail sent out automatically every
month.
How would I go about doing this? As a user can take their course at
any time in the month I'd need to send them a reminder on that date
every calendar month.
Well, assuming that you have a database containing a list of users,
which contains the date they started their course, it shouldn't be hard
to set up a cron job that looks for people who should be emailed, and
email them.
Most of the complexity comes from working with dates. For instance, you
say "that date every calendar month" - what if they signed up 31st Jan?
31st + Jan + 1 month - is that 28th Feb or 1st March?
Let a decent date library take most of the strain, and it shouldn't be
too hard.
For the easiest approach, email them every 30 days, then you can just
have a cron job that looks for all users where the
"last_sent_nagging_email" column is 30 days ago, and send them the email
(then update that column, so that they don't get emailed again until
it's due). That takes away most of the nasty date manipulation :)
Cheers
Dave P
____ The WDVL Discussion List from WDVL.COM ____
To Join wdvltalk, Send An Email To:
mailto:subscribe-wdvlt...@intm-dl.sparklist.com or
use the web interface http://e-newsletters.internet.com/discussionlists.html/
Send Your Posts To: wdvltalk@lists.wdvl.com
To change subscription settings, add a password or view the web interface:
http://intm-dl.sparklist.com/read/?forum=wdvltalk
________________ http://www.wdvl.com _______________________
You are currently subscribed to wdvltalk as: arch...@jab.org
To unsubscribe send a blank email to
leave-50556369-230552.f22dcf5120bad5a91a87f69f1e923...@lists.wdvl.com
To unsubscribe via postal mail, please contact us at:
Jupitermedia Corp.
Attn: Discussion List Management
475 Park Avenue South
New York, NY 10016
Please include the email address which you have been contacted with.