finish() 공개 메소드

shortens notices to the last 50
public finish ( $id, $cancel = false, $test = false )
예제 #1
0
파일: Pommo_Mta.php 프로젝트: soonick/poMMo
 function stop($finish = false)
 {
     $this->_mailer->SmtpClose();
     if ($this->_test) {
         // don't respawn if this is a test mailing
         Pommo_Mail_Ctl::finish($this->_id, TRUE, TRUE);
         Pommo_Subscribers::delete(current($this->_hash));
         session_destroy();
         exit;
     }
     if ($finish) {
         Pommo_Mail_Ctl::finish($this->_id);
         $this->shutdown(Pommo::_T('Mailing Complete.'));
     }
     // respwn
     if (!Pommo_Mail_Ctl::spawn(Pommo::$_baseUrl . 'ajax/mailings_send4.php?' . 'code=' . $this->_code . '&serial=' . $this->_serial . '&id=' . $this->_id)) {
         $this->shutdown('*** RESPAWN FAILED! ***');
     }
     $this->shutdown(sprintf(Pommo::_T('Runtime (%s seconds) reached, respawning.'), $this->_maxRunTime), false);
 }