Jump to content

handling events on a date


1internet

Recommended Posts

I want to send an email every 7 days. Essentially a row is picked out at random from a database, and their email address is taken and they are emailed. Every 7 days another one at random is chosen, and again they are emailed.

 

So I am guessing it would have something to do with the current date, and then worked out somehow if it is a multiple of 7 and if so email them that day? I am not entirely sure, and really cant get my head around this one. How is this done?

Link to comment
Share on other sites

You simply need create a script to perform the process as you described. Then create a scheduled task to run every seven days to execute that task. On a Linux server this is typically handled through a CRON job. Your host should have a way of scheduling these

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.