Forum Moderators: coopster
This script will be for multiple users all picking different times.
This is possible to do with PHP? Would it be reliable?
/usr/local/php5/bin/php5 /home/site/folder/send_email.php
On my server, this tells php5 to run the file specified. (Modify as needed per the location of php and your files on the server.) This is also assuming you're accessing cron through a cpanel-like interface.
You'd have to make sure you didn't resend any emails that were already sent once (so $time<=time() wouldn't work). IMO the best approach would be to have a field in the DB called "sent" and set it to 1 once you've sent the email. Then, look for anything due to be sent at or before time() that has sent=0. Send the email, then update the DB to set sent = 1.