Property | Type | Description | |
---|---|---|---|
$alt_message | string | Alternative message (for HTML messages only) | |
$bcc_batch_mode | boolean | Whether to send messages to BCC recipients in batches. | |
$bcc_batch_size | integer | BCC Batch max number size. | |
$charset | string | Character set (default: utf-8) | |
$crlf | string | RFC 2045 specifies that for 'quoted-printable' encoding, "\r\n" must be used. However, it appears that some servers (even on the receiving end) don't handle it properly and switching to "\n", while improper, is the only solution that seems to work for all environments. | |
$dsn | boolean | Whether to use Delivery Status Notification. | |
$mailpath | string | Path to the Sendmail binary. | |
$mailtype | Message format. | ||
$multipart | Multipart message | ||
$newline | Use "\r\n" to comply with RFC 822. | ||
$priority | X-Priority header value. | ||
$protocol | Which method to use for sending e-mails. | ||
$send_multipart | boolean | Yahoo! doesn't seem to like these. | |
$smtp_crypto | SMTP Encryption | ||
$smtp_host | string | STMP Server host | |
$smtp_keepalive | boolean | SMTP persistent connection | |
$smtp_pass | string | SMTP Password | |
$smtp_port | integer | SMTP Server port | |
$smtp_timeout | integer | SMTP connection timeout in seconds | |
$smtp_user | string | SMTP Username | |
$useragent | string | Used as the User-Agent and X-Mailer headers' value. | |
$validate | boolean | Whether to validate e-mail addresses. | |
$wordwrap | boolean | Whether to apply word-wrapping to the message body. | |
$wrapchars | integer | Number of characters to wrap at. |
Property | Type | Description | |
---|---|---|---|
$_alt_boundary | string | multipart/alternative boundary | |
$_atc_boundary | string | Attachment boundary | |
$_attachments | array | Attachment data | |
$_base_charsets | string[] | Character sets valid for 7-bit encoding, excluding language suffix. | |
$_bcc_array | string[] | BCC Recipients | |
$_bit_depths | string[] | Valid mail encodings | |
$_body | string | Message body | |
$_cc_array | string[] | CC Recipients | |
$_debug_msg | string | Debug messages | |
$_encoding | Mail encoding | ||
$_finalbody | string | Final message body to be sent. | |
$_header_str | string | Final headers to send | |
$_headers | string[] | Message headers | |
$_priorities | string[] | Actual values to send with the X-Priority header | |
$_protocols | string[] | Valid $protocol values | |
$_recipients | string[] | Recipients | |
$_replyto_flag | boolean | Whether to send a Reply-To header | |
$_safe_mode | boolean | Whether PHP is running in safe mode. Initialized by the class constructor. | |
$_smtp_auth | boolean | Whether to perform SMTP authentication | |
$_smtp_connect | resource | SMTP Connection socket placeholder | |
$_subject | string | Subject header |
Method | Description | |
---|---|---|
__construct ( array $config = [] ) : void | Constructor - Sets Email Preferences | |
__destruct ( ) : void | Destructor - Releases Resources | |
attach ( string $file, string $disposition = '', string $newname = NULL, string $mime = '' ) : CI_Email | Assign file attachments | |
attachment_cid ( string $filename ) : string | Set and return attachment Content-ID | |
batch_bcc_send ( ) : void | Batch Bcc Send. Sends groups of BCCs in batches | |
bcc ( $bcc, $limit = '' ) : CI_Email | Set BCC | |
cc ( $cc ) : CI_Email | Set CC | |
clean_email ( $email ) : string |
Clean Extended Email Address: Joe Smith |
|
clear ( $clear_attachments = FALSE ) : CI_Email | Initialize the Email Data | |
from ( string $from, string $name = '', string $return_path = NULL ) : CI_Email | Set FROM | |
initialize ( $config = [] ) : CI_Email | Initialize preferences | |
message ( $body ) : CI_Email | Set Body | |
print_debugger ( array $include = ['headers', 'subject', 'body'] ) : string | Get Debug Message | |
reply_to ( $replyto, $name = '' ) : CI_Email | Set Reply-to | |
send ( boolean $auto_clear = TRUE ) : boolean | Send Email | |
set_alt_message ( $str ) : CI_Email | Set Multipart Value | |
set_crlf ( $crlf = " " ) : CI_Email | Set CRLF | |
set_header ( $header, $value ) : CI_Email | Add a Header Item | |
set_mailtype ( $type = 'text' ) : CI_Email | Set Mailtype | |
set_newline ( $newline = " " ) : CI_Email | Set Newline Character | |
set_priority ( $n = 3 ) : CI_Email | Set Priority | |
set_protocol ( $protocol = 'mail' ) : CI_Email | Set Protocol | |
set_wordwrap ( $wordwrap = TRUE ) : CI_Email | Set Wordwrap | |
subject ( $subject ) : CI_Email | Set Email Subject | |
to ( $to ) : CI_Email | Set Recipients | |
valid_email ( $email ) : boolean | Email Validation | |
validate_email ( $email ) : boolean | Validate Email Address | |
word_wrap ( $str, $charlim = NULL ) : string | Word Wrap |
Method | Description | |
---|---|---|
_build_headers ( ) : string | Build final headers | |
_build_message ( ) : boolean | Build Final Body and attachments | |
_get_alt_message ( ) : string | Build alternative plain text message | |
_get_content_type ( ) : string | Get content type (text/html/attachment) | |
_get_encoding ( $return = TRUE ) : string | Get Mail Encoding | |
_get_hostname ( ) : string | Get Hostname | |
_get_message_id ( ) : string | Get the Message ID | |
_get_mime_message ( ) : string | Mime message | |
_get_protocol ( $return = TRUE ) : mixed | Get Mail Protocol | |
_get_smtp_data ( ) : string | Get SMTP data | |
_mime_types ( $ext = '' ) : string | Mime Types | |
_prep_q_encoding ( $str ) : string | Prep Q Encoding | |
_prep_quoted_printable ( $str ) : string | Prep Quoted Printable | |
_remove_nl_callback ( string $matches ) : string | Strip line-breaks via callback | |
_send_command ( $cmd, $data = '' ) : string | Send SMTP command | |
_send_data ( string $data ) : boolean | Send SMTP data | |
_send_with_mail ( ) : boolean | Send using mail() | |
_send_with_sendmail ( ) : boolean | Send using Sendmail | |
_send_with_smtp ( ) : boolean | Send using SMTP | |
_set_boundaries ( ) : void | Set Message Boundary | |
_set_date ( ) : string | Set RFC 822 Date | |
_set_error_message ( string $msg, string $val = '' ) : void | Set Message | |
_smtp_authenticate ( ) : boolean | SMTP Authenticate | |
_smtp_connect ( ) : string | SMTP Connect | |
_spool_email ( ) : boolean | Spool mail to the mail server | |
_str_to_array ( $email ) : array | Convert a String to an Array | |
_unwrap_specials ( ) : void | Unwrap special elements | |
_write_headers ( ) : void | Write Headers as a string |
public __construct ( array $config = [] ) : void | ||
$config | array | = array() |
return | void |
protected _build_headers ( ) : string | ||
return | string |
protected _build_message ( ) : boolean | ||
return | boolean |
protected _get_alt_message ( ) : string | ||
return | string |
protected _get_content_type ( ) : string | ||
return | string |
protected _get_encoding ( $return = TRUE ) : string | ||
return | string |
protected _get_hostname ( ) : string | ||
return | string |
protected _get_message_id ( ) : string | ||
return | string |
protected _get_mime_message ( ) : string | ||
return | string |
protected _get_protocol ( $return = TRUE ) : mixed | ||
return | mixed |
protected _mime_types ( $ext = '' ) : string | ||
return | string |
protected _prep_q_encoding ( $str ) : string | ||
return | string |
protected _prep_quoted_printable ( $str ) : string | ||
return | string |
protected _remove_nl_callback ( string $matches ) : string | ||
$matches | string | |
return | string |
protected _send_command ( $cmd, $data = '' ) : string | ||
return | string |
protected _send_data ( string $data ) : boolean | ||
$data | string | |
return | boolean |
protected _send_with_mail ( ) : boolean | ||
return | boolean |
protected _send_with_sendmail ( ) : boolean | ||
return | boolean |
protected _send_with_smtp ( ) : boolean | ||
return | boolean |
protected _set_boundaries ( ) : void | ||
return | void |
protected _smtp_authenticate ( ) : boolean | ||
return | boolean |
protected _spool_email ( ) : boolean | ||
return | boolean |
protected _str_to_array ( $email ) : array | ||
return | array |
protected _unwrap_specials ( ) : void | ||
return | void |
protected _write_headers ( ) : void | ||
return | void |
public attachment_cid ( string $filename ) : string | ||
$filename | string | |
return | string |
public batch_bcc_send ( ) : void | ||
return | void |
public clean_email ( $email ) : string | ||
return | string |
public clear ( $clear_attachments = FALSE ) : CI_Email | ||
return | CI_Email |
public initialize ( $config = [] ) : CI_Email | ||
return | CI_Email |
public print_debugger ( array $include = ['headers', 'subject', 'body'] ) : string | ||
$include | array | List of raw data chunks to include in the output Valid options are: 'headers', 'subject', 'body' |
return | string |
public reply_to ( $replyto, $name = '' ) : CI_Email | ||
return | CI_Email |
public set_alt_message ( $str ) : CI_Email | ||
return | CI_Email |
public set_header ( $header, $value ) : CI_Email | ||
return | CI_Email |
public set_mailtype ( $type = 'text' ) : CI_Email | ||
return | CI_Email |
public set_newline ( $newline = " " ) : CI_Email | ||
return | CI_Email |
public set_protocol ( $protocol = 'mail' ) : CI_Email | ||
return | CI_Email |
public set_wordwrap ( $wordwrap = TRUE ) : CI_Email | ||
return | CI_Email |
public validate_email ( $email ) : boolean | ||
return | boolean |
protected string $_alt_boundary | ||
return | string |
protected string[] $_base_charsets | ||
return | string[] |
protected string[] $_bit_depths | ||
return | string[] |
protected string $_finalbody | ||
return | string |
protected string[] $_priorities | ||
return | string[] |
protected string[] $_protocols | ||
return | string[] |
protected bool $_replyto_flag | ||
return | boolean |
protected bool $_safe_mode | ||
return | boolean |
protected bool $_smtp_auth | ||
return | boolean |
protected resource $_smtp_connect | ||
return | resource |
public string $alt_message | ||
return | string |
public bool $bcc_batch_mode | ||
return | boolean |
public int $bcc_batch_size | ||
return | integer |
public string $crlf | ||
return | string |
public bool $send_multipart | ||
return | boolean |
public bool $smtp_keepalive | ||
return | boolean |
public int $smtp_timeout | ||
return | integer |
public string $useragent | ||
return | string |
public bool $validate | ||
return | boolean |
public bool $wordwrap | ||
return | boolean |