ListMailPRO Email Marketing Software Forums

ListMailPRO Email Marketing Software Forums => General Help & How-To => Topic started by: chief on November 19, 2007, 06:22:10 am

Title: cron - next message to send
Post by: chief on November 19, 2007, 06:22:10 am
Is there a way to look somewhere to figure out what the next message the cron is qued to send?

I know I can look at the user database - delay column- and when it is  - 0 - the cron wil send the message at the skd. time.

but - is it possible to look somewhere in the cron code to actually see the code that the cron will execute.?
Thanks
Title: cron - next message to send
Post by: DW on November 20, 2007, 04:30:59 am
You know when delay is 0 the message will be sent next dailymail.  I believe you are asking if there is a way to see when "Cron-style Followups" are due to be sent - is that right?  Currently this is not possible and it would take a fair custom script to achieve it.  You can find the code in the dailymail.php file...
Code: [Select]
include('./cron.php');
  $cr = new cron;
  $now = date("Ymd",time());

Code: [Select]
        while(list($mid,$cron)=mysql_fetch_row($result5)){
          if($cron){
           $cr->calcLastRan("* * ".$cron);
           $due = date("Ymd",$cr->getLastRanUnix()-1);
           if($now == $due){
            $sendids[] = $mid;
            if($DEBUG) echo " Delay is 0 and cron is due on the new message - sending!<br>";
           }
          }

If you know PHP you could create a script to look ahead a number of days and run the cron test for each followup...  This could further be cross-referenced with users, but it is definitely a non-trivial job!

Regards