From 37f4b9caa02783e06dd7c5318200113409a0deb1 Mon Sep 17 00:00:00 2001 From: Derek Jones Date: Fri, 1 Jul 2011 17:56:50 -0500 Subject: backed out 648b42a75739, which was a NON-trivial whitespace commit. It broke the Typography class's string replacements, for instance --- user_guide/libraries/email.html | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) (limited to 'user_guide/libraries/email.html') diff --git a/user_guide/libraries/email.html b/user_guide/libraries/email.html index 61e139187..5a8814d59 100644 --- a/user_guide/libraries/email.html +++ b/user_guide/libraries/email.html @@ -78,7 +78,7 @@ Email Class

Sending email is not only simple, but you can configure it on the fly or set your preferences in a config file.

-

Here is a basic example demonstrating how you might send email. Note: This example assumes you are sending the email from one of your +

Here is a basic example demonstrating how you might send email. Note: This example assumes you are sending the email from one of your controllers.

$this->load->library('email');
@@ -103,7 +103,7 @@ echo $this->email->print_debugger();

There are 17 different preferences available to tailor how your email messages are sent. You can either set them manually as described here, or automatically via preferences stored in your config file, described below:

-

Preferences are set by passing an array of preference values to the email initialize function. Here is an example of how you might set some preferences:

+

Preferences are set by passing an array of preference values to the email initialize function. Here is an example of how you might set some preferences:

$config['protocol'] = 'sendmail';
$config['mailpath'] = '/usr/sbin/sendmail';
@@ -117,7 +117,7 @@ $this->email->initialize($config);
>

Setting Email Preferences in a Config File

If you prefer not to set preferences using the above method, you can instead put them into a config file. -Simply create a new file called the email.php, add the $config +Simply create a new file called the email.php, add the $config array in that file. Then save the file at config/email.php and it will be used automatically. You will NOT need to use the $this->email->initialize() function if you save your preferences in a config file.

@@ -156,13 +156,13 @@ will NOT need to use the $this->email->initialize() function if you s wrapchars76 Character count to wrap at. -mailtypetexttext or htmlType of mail. If you send HTML email you must send it as a complete web page. Make sure you don't have any relative links or relative image paths otherwise they will not work. +mailtypetexttext or htmlType of mail. If you send HTML email you must send it as a complete web page. Make sure you don't have any relative links or relative image paths otherwise they will not work. charsetutf-8Character set (utf-8, iso-8859-1, etc.). -validateFALSETRUE or FALSE (boolean)Whether to validate the email address. +validateFALSETRUE or FALSE (boolean)Whether to validate the email address. -priority31, 2, 3, 4, 5Email Priority. 1 = highest. 5 = lowest. 3 = normal. +priority31, 2, 3, 4, 5Email Priority. 1 = highest. 5 = lowest. 3 = normal. crlf @@ -188,12 +188,12 @@ will NOT need to use the $this->email->initialize() function if you s $this->email->from('you@example.com', 'Your Name');

$this->email->reply_to()

-

Sets the reply-to address. If the information is not provided the information in the "from" function is used. Example:

+

Sets the reply-to address. If the information is not provided the information in the "from" function is used. Example:

$this->email->reply_to('you@example.com', 'Your Name');

$this->email->to()

-

Sets the email address(s) of the recipient(s). Can be a single email, a comma-delimited list or an array:

+

Sets the email address(s) of the recipient(s). Can be a single email, a comma-delimited list or an array:

$this->email->to('someone@example.com'); $this->email->to('one@example.com, two@example.com, three@example.com'); @@ -221,14 +221,14 @@ $this->email->to($list);

Sets the alternative email message body:

$this->email->set_alt_message('This is the alternative message'); -

This is an optional message string which can be used if you send HTML formatted email. It lets you specify an alternative +

This is an optional message string which can be used if you send HTML formatted email. It lets you specify an alternative message with no HTML formatting which is added to the header string for people who do not accept HTML email. If you do not set your own message CodeIgniter will extract the message from your HTML email and strip the tags.

$this->email->clear()

-

Initializes all the email variables to an empty state. This function is intended for use if you run the email sending function +

Initializes all the email variables to an empty state. This function is intended for use if you run the email sending function in a loop, permitting the data to be reset between cycles.

foreach ($list as $name => $address)
{
@@ -268,13 +268,13 @@ $this->email->send();

$this->email->print_debugger()

-

Returns a string containing any server messages, the email headers, and the email messsage. Useful for debugging.

+

Returns a string containing any server messages, the email headers, and the email messsage. Useful for debugging.

Overriding Word Wrapping

If you have word wrapping enabled (recommended to comply with RFC 822) and you have a very long link in your email it can -get wrapped too, causing it to become un-clickable by the person receiving it. CodeIgniter lets you manually override +get wrapped too, causing it to become un-clickable by the person receiving it. CodeIgniter lets you manually override word wrapping within part of your message like this:

The text of your email that
-- cgit v1.2.3-24-g4f1b