PHP 클래스 Mail, huge

User: Hp Date: 06/06/2015 Time: 14:33
파일 보기 프로젝트 열기: panique/huge 1 사용 예제들

공개 메소드들

메소드 설명
getError ( ) : mixed The different mail sending methods write errors to the error property $this->error, this method simply returns this error / error array.
sendMail ( $user_email, $from_email, $from_name, $subject, $body ) : boolean The main mail sending method, this simply calls a certain mail sending method depending on which mail provider you've selected in the application's config.
sendMailWithNativeMailFunction ( ) Try to send a mail by using PHP's native mail() function.
sendMailWithPHPMailer ( $user_email, $from_email, $from_name, $subject, $body ) : boolean Try to send a mail by using PHPMailer.
sendMailWithSwiftMailer ( ) : boolean Try to send a mail by using SwiftMailer.

메소드 상세

getError() 공개 메소드

The different mail sending methods write errors to the error property $this->error, this method simply returns this error / error array.
public getError ( ) : mixed
리턴 mixed

sendMail() 공개 메소드

The main mail sending method, this simply calls a certain mail sending method depending on which mail provider you've selected in the application's config.
public sendMail ( $user_email, $from_email, $from_name, $subject, $body ) : boolean
$user_email string email
$from_email string sender's email
$from_name string sender's name
$subject string subject
$body string full mail body text
리턴 boolean the success status of the according mail sending method

sendMailWithNativeMailFunction() 공개 메소드

Please note that not PHP itself will send a mail, it's just a wrapper for Linux's sendmail or other mail tools Good guideline on how to send mails natively with mail():
또한 보기: http://stackoverflow.com/a/24644450/1114320
또한 보기: http://www.php.net/manual/en/function.mail.php

sendMailWithPHPMailer() 공개 메소드

Make sure you have loaded PHPMailer via Composer. Depending on your EMAIL_USE_SMTP setting this will work via SMTP credentials or via native mail()
public sendMailWithPHPMailer ( $user_email, $from_email, $from_name, $subject, $body ) : boolean
$user_email
$from_email
$from_name
$subject
$body
리턴 boolean

sendMailWithSwiftMailer() 공개 메소드

Make sure you have loaded SwiftMailer via Composer.