Class Net_PHPMailer
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
boolean
|
|
public
boolean
|
|
public
boolean
|
|
public
boolean
|
|
protected
boolean
|
#
AddAnAddress( string $kind, string $address, string $name = '' )
Adds an address to one of the recipient arrays Addresses that have been added already return false, but do not throw exceptions |
public
boolean
|
|
public static
boolean
|
#
ValidateAddress( string $address )
Check that a string looks roughly like an email address should Static so it can be used without instantiation Tries to use PHP built-in validator in the filter extension (from PHP 5.2), falls back to a reasonably competent regex validator Conforms approximately to RFC2822 |
public
boolean
|
|
protected
|
|
protected
|
|
protected
boolean
|
|
protected
boolean
|
|
protected
boolean
|
|
public
boolean
|
|
public
|
|
public
|
#
SetLanguage( string $langcode = 'en', string $lang_path = 'language/' )
Sets the language for all class error messages. Returns false if it cannot load the language file. The default language is English. |
public
array
|
|
public
string
|
|
public
string
|
|
public
string
|
|
public
integer
|
#
UTF8CharBoundary( string $encodedText, integer $maxLength )
Finds last character boundary prior to maxLength in a utf-8 quoted (printable) encoded string. Original written by Colin Brown. |
public
|
|
public
string
|
|
public
string
|
|
public
string
|
#
GetSentMIMEMessage( )
Returns the MIME message (headers and body). Only really valid post PreSend(). |
public
string
|
|
protected
string
|
#
GetBoundary( $boundary, $charSet, $contentType, $encoding )
Returns the start of a message boundary. |
protected
string
|
|
protected
|
|
public
string
|
|
public
string
|
|
public
boolean
|
#
AddAttachment( string $path, string $name = '', string $encoding = 'base64', string $type = 'application/octet-stream' )
Adds an attachment from a path on the filesystem. Returns false if the file could not be found or accessed. |
public
array
|
|
protected
string
|
|
protected
string
|
#
EncodeFile( string $path, string $encoding = 'base64' )
Encodes attachment in requested format. Returns an empty string on failure. |
public
string
|
#
EncodeString( string $str, string $encoding = 'base64' )
Encodes string to requested format. Returns an empty string on failure. |
public
string
|
#
EncodeHeader( $str, $position = 'text' )
Encode a header string to best (shortest) of Q, B, quoted or none. |
public
boolean
|
|
public
string
|
#
Base64EncodeWrapMB( string $str )
Correctly encodes and wraps long multibyte strings for mail headers without breaking lines within a character. Adapted from a function by paravoid at http://uk.php.net/manual/en/function.mb-encode-mimeheader.php |
public
string
|
#
EncodeQPphp( string $input = '', integer $line_max = 76, $space_conv = false )
Encode string to quoted-printable. Only uses standard PHP, slow, but will always work |
public
string
|
|
public
string
|
|
public
|
#
AddStringAttachment( string $string, string $filename, string $encoding = 'base64', string $type = 'application/octet-stream' )
Adds a string or binary attachment (non-filesystem) to the list. This method can be used to attach ascii or binary data, such as a BLOB record from a database. |
public
boolean
|
#
AddEmbeddedImage( string $path, string $cid, string $name = '', string $encoding = 'base64', string $type = 'application/octet-stream' )
Adds an embedded attachment. This can include images, sounds, and just about any other document. Make sure to set the $type to an image type. For JPEG images use "image/jpeg" and for GIF images use "image/gif". |
public
|
#
AddStringEmbeddedImage( $string, $cid, $filename = '', $encoding = 'base64', $type = 'application/octet-stream' )
|
public
boolean
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
#
ClearAttachments( )
Clears all previously set filesystem, string, and binary attachments. Returns void. |
public
|
|
protected
|
|
public static
string
|
|
protected
string
|
|
protected
string
|
|
public
boolean
|
|
public
string
|
|
public
|
|
public
$message
|
|
public static
string
|
|
public
|
|
public
string
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
protected
|
integer
|
STOP_MESSAGE
|
0 |
|
integer
|
STOP_CONTINUE
|
1 |
|
integer
|
STOP_CRITICAL
|
2 |
public
integer
|
$Priority | 3 |
#
Email priority (1 = High, 3 = Normal, 5 = low). |
public
string
|
$CharSet | 'iso-8859-1' |
#
Sets the CharSet of the message. |
public
string
|
$ContentType | 'text/plain' |
#
Sets the Content-type of the message. |
public
string
|
$Encoding | '8bit' |
#
Sets the Encoding of the message. Options for this are |
public
string
|
$ErrorInfo | '' |
#
Holds the most recent mailer error message. |
public
string
|
$From | 'root@localhost' |
#
Sets the From email address for the message. |
public
string
|
$FromName | 'Root User' |
#
Sets the From name of the message. |
public
string
|
$Sender | '' |
#
Sets the Sender email (Return-Path) of the message. If not empty, will be sent via -f to sendmail or as 'MAIL FROM' in smtp mode. |
public
string
|
$Subject | '' |
#
Sets the Subject of the message. |
public
string
|
$Body | '' |
#
Sets the Body of the message. This can be either an HTML or text body. If HTML then run IsHTML(true). |
public
string
|
$AltBody | '' |
#
Sets the text-only body of the message. This automatically sets the email to multipart/alternative. This body can be read by mail clients that do not have HTML email capability such as mutt. Clients that can read HTML will view the normal Body. |
protected
string
|
$MIMEBody | '' |
#
Stores the complete compiled MIME message body. |
protected
string
|
$MIMEHeader | '' |
#
Stores the complete compiled MIME message headers. |
protected
string
|
$SentMIMEMessage | '' |
#
Stores the complete sent MIME message (Body and Headers) |
public
integer
|
$WordWrap | 0 |
#
Sets word wrapping on the body of the message to a given number of characters. |
public
string
|
$Mailer | 'mail' |
#
Method to send mail: ("mail", "sendmail", or "smtp"). |
public
string
|
$Sendmail | '/usr/sbin/sendmail' |
#
Sets the path of the sendmail program. |
public
string
|
$PluginDir | '' |
#
Path to PHPMailer plugins. Useful if the SMTP class is in a different directory than the PHP include path. |
public
string
|
$ConfirmReadingTo | '' |
#
Sets the email address that a reading confirmation will be sent. |
public
string
|
$Hostname | '' |
#
Sets the hostname to use in Message-Id and Received headers and as default HELO string. If empty, the value returned by SERVER_NAME is used or 'localhost.localdomain'. |
public
string
|
$MessageID | '' |
#
Sets the message ID to be used in the Message-Id header. If empty, a unique id will be generated. |
public
string
|
$Host | 'localhost' |
#
Sets the SMTP hosts. All hosts must be separated by a semicolon. You can also specify a different port for each host by using this format: [hostname:port] (e.g. "smtp1.example.com:25;smtp2.example.com"). Hosts will be tried in order. |
public
integer
|
$Port | 25 |
#
Sets the default SMTP server port. |
public
string
|
$Helo | '' |
#
Sets the SMTP HELO of the message (Default is $Hostname). |
public
string
|
$SMTPSecure | '' |
#
Sets connection prefix. Options are "", "ssl" or "tls" |
public
boolean
|
$SMTPAuth | false |
#
Sets SMTP authentication. Utilizes the Username and Password variables. |
public
string
|
$Username | '' |
#
Sets SMTP username. |
public
string
|
$Password | '' |
#
Sets SMTP password. |
public
integer
|
$Timeout | 10 |
#
Sets the SMTP server timeout in seconds. This function will not work with the win32 version. |
public
boolean
|
$SMTPDebug | false |
#
Sets SMTP class debugging on or off. |
public
boolean
|
$SMTPKeepAlive | false |
#
Prevents the SMTP connection from being closed after each mail sending. If this is set to true then to close the connection requires an explicit call to SmtpClose(). |
public
boolean
|
$SingleTo | false |
#
Provides the ability to have the TO field process individual emails, instead of sending to entire TO addresses |
public
boolean
|
$SingleToArray | array() |
#
If SingleTo is true, this provides the array to hold the email addresses |
public
string
|
$LE | "\n" |
#
Provides the ability to change the line ending |
public
string
|
$DKIM_selector | 'phpmailer' |
#
Used with DKIM DNS Resource Record |
public
string
|
$DKIM_identity | '' |
#
Used with DKIM DNS Resource Record optional, in format of email address 'you@yourdomain.com' |
public
string
|
$DKIM_passphrase | '' |
#
Used with DKIM DNS Resource Record |
public
string
|
$DKIM_domain | '' |
#
Used with DKIM DNS Resource Record optional, in format of email address 'you@yourdomain.com' |
public
string
|
$DKIM_private | '' |
#
Used with DKIM DNS Resource Record optional, in format of email address 'you@yourdomain.com' |
public
string
|
$action_function | '' |
#
Callback Action function name the function that handles the result of the
send email action. Parameters: |
public
string
|
$Version | '5.2.1' |
#
Sets the PHPMailer Version number |
public
string
|
$XMailer | '' |
#
What to use in the X-Mailer header |
protected
|
$smtp | NULL |
|
protected
array
|
$to | array() |
|
protected
array
|
$cc | array() |
|
protected
array
|
$bcc | array() |
|
protected
array
|
$ReplyTo | array() |
|
protected
array
|
$all_recipients | array() |
|
protected
array
|
$attachment | array() |
|
protected
array
|
$CustomHeader | array() |
|
protected
string
|
$message_type | '' |
|
protected
array
|
$boundary | array() |
|
protected
array
|
$language | array() |
|
protected
integer
|
$error_count | 0 |
|
protected
string
|
$sign_cert_file | '' |
|
protected
string
|
$sign_key_file | '' |
|
protected
string
|
$sign_key_pass | '' |
|
protected
boolean
|
$exceptions | false |