title: Scheduled calling function in php
body: <p>I need to send an email containing which employees are coming late after a specified point in time. </p>
  
  <p>Example:</p>
  
  <pre><code>class ControllerName
  {
    public function emailSendingAction()
    {
        //Fetching employee details from database
        //code to send an email
     }
  } 
  </code></pre>
  
  <p>How can I call that function at the specified time?</p>
  
  <p>I googled it and found <strong>crontab</strong>. </p>
  
  <p>How can I call that function using crontab? Or is their any other method?</p>
  
  <p><strong>Note:</strong> The scheduled time should be fetched from a database column value.</p>
  
  <p>If crontab is best option, then how do I use it?</p>