Re: PHP and schedules tasks/events

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



you can setup a schedule table in db
and have a cron php script check the db every time
and send email if the current time is around the scheduled_at time
and close the schedule after you send the email

On Fri, Apr 16, 2010 at 5:35 PM, Adam Richardson <simpleshot@xxxxxxxxx> wrote:
> On Fri, Apr 16, 2010 at 5:15 PM, Don Wieland <donw@xxxxxxxxxxxxxxxxxx>wrote:
>
>> On Apr 16, 2010, at 1:26 PM, Bastien Koert wrote:
>>
>>  Run a cronjob at midnight and send the email. Track who it got sent
>>> to, so you don't duplicate it. Easy peasy!
>>>
>>
>> This is fine if the email is to be sent at midnight.
>>
>> I am looking for more refinement.
>>
>> For example:
>>
>> A user signs up for an event - 4/16/2010 @ 10:45am
>>
>> There is an option:
>>
>> Send me a reminder email X minutes/hours/days/weeks/months/years prior to
>> the Event.
>>
>> so:
>>
>> 30 minute(s) = email sent at 4/16/2010 @ 10:15am
>> 2 hour(s) = email sent at 4/16/2010 @ 8:45am
>> 3 day(s) = email sent at 4/13/2010 @ 10:45am
>> 1 week(s) = email sent at 4/9/2010 @ 10:45am
>> 1 month(s) = email sent at 3/16/2010 @ 10:45am
>> 1 year(s) = email sent at 4/16/2009 @ 10:45am
>>
>> This is really what I need...
>>
>>
>> Don Wieland
>> D W   D a t a   C o n c e p t s
>> ~~~~~~~~~~~~~~~~~~~~~~~~~
>> donw@xxxxxxxxxxxxxxxxxx
>> Direct Line - (949) 305-2771
>>
>> --
>> PHP General Mailing List (http://www.php.net/)
>> To unsubscribe, visit: http://www.php.net/unsub.php
>>
>>
> What about making ics files available for download?  Users could easily
> import the event into the calendar of choice, and they could also (using the
> calendar software they're already familiar with) set the alarm.  For
> instance, I can set the calendar on my cell to ring my phone to alert me to
> events (my preference over email reminders for important events because I
> sometimes get flooded with email.)
>
> Your scripts could generate the files containing event info and then
> automatically start the download.
>
> This allows the users to determine the mode of alarm that works best for
> them in their native calendar app, and you're still greatly facilitating the
> process by providing all of the info so they merely have to drag and drop
> for many apps.
>
> I realize you asked specifically for a server-side email alarm solution (I
> apologize for the tangent if your needs preclude this type of approach), but
> I thought I'd toss out the idea as this approach has proved more effective
> and efficient for websites I maintain.
>
> Adam
>
> --
> Nephtali:  PHP web framework that functions beautifully
> http://nephtaliproject.com
>

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux