Exemple #1
0
 private function smtpSend()
 {
     $smtp = new Smtp();
     try {
         $smtp->open($this->hostname, $this->port, $this->timeout);
         $smtp->hello($this->hello);
         $smtp->auth($this->user, $this->pwd);
         $smtp->from($this->from);
         $smtp->to($this->to);
         $smtp->data($this->subject, $this->message);
         $smtp->quit();
         $smtp->close();
     } catch (Exception $e) {
         throw new Exception($e);
     }
 }