How to send mail to php at scheduled time?

I want to create an application that allows users to send emails to be sent at any time. just write an email message and write it so that the server sends it at the specified time. I am using zend framework. How to do this in php? Can this be done with cron? If so, what are the disadvantages of using cron?

+3
source share
2 answers

Can this be done with cron jobs?

Cron is a time task scheduler on Unix-like computer operating systems. The name cron comes from the word chronos, the Greek word for time. 1 Cron allows users to schedule tasks (commands or shell scripts) to run periodically at specific points in time or date. It is commonly used to automate the maintenance or administration of a system, although its universal nature means that it can be used for other purposes, such as connecting to the Internet and downloading e-mail.

http://ubuntuforums.org/showthread.php?t=586478

I run a cron job every minute and check if there are any emails ready for scheduling. A quote from the forum thread below gives instructions on how to start cron every minute.

crontab -e

* * * * * /command

- ,

, 5 ,

*/5 * * * * /command/to/execute

dayofweek *

* 0 =

cron?

, cron

cronjobs, ( , ). , . cronjob , , .

+3

cron.

script, . 1PM ( , ), script 5 , (db), - ? , , .

.

?

, , cron, .

+3

Source: https://habr.com/ru/post/1782196/


All Articles