Skip to content

Commit

Permalink
Don't set WordWrap in readme example, add comments about usage includ…
Browse files Browse the repository at this point in the history
…ing 78 as a good value to use, fixes PHPMailer#327
  • Loading branch information
Synchro committed Dec 6, 2014
1 parent de5c035 commit ba4ece8
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
1 change: 0 additions & 1 deletion README.md
Expand Up @@ -71,7 +71,6 @@ $mail->addReplyTo('info@example.com', 'Information');
$mail->addCC('cc@example.com');
$mail->addBCC('bcc@example.com');

$mail->WordWrap = 50; // Set word wrap to 50 characters
$mail->addAttachment('/var/tmp/file.tar.gz'); // Add attachments
$mail->addAttachment('/tmp/image.jpg', 'new.jpg'); // Optional name
$mail->isHTML(true); // Set email format to HTML
Expand Down
1 change: 1 addition & 0 deletions class.phpmailer.php
Expand Up @@ -149,6 +149,7 @@ class PHPMailer

/**
* Word-wrap the message body to this number of chars.
* Set to 0 to not wrap. A useful value here is 78, for RFC2822 section 2.1.1 compliance.
* @type integer
*/
public $WordWrap = 0;
Expand Down
4 changes: 2 additions & 2 deletions examples/code_generator.phps
Expand Up @@ -172,10 +172,10 @@ try {

$example_code .= "\n\$body = <<<'EOT'\n" . htmlentities($body) . "\nEOT;";

$mail->WordWrap = 80; // set word wrap
$mail->WordWrap = 78; // set word wrap to the RFC2822 limit
$mail->msgHTML($body, dirname(__FILE__), true); //Create message bodies and embed images

$example_code .= "\n\$mail->WordWrap = 80;";
$example_code .= "\n\$mail->WordWrap = 78;";
$example_code .= "\n\$mail->msgHTML(\$body, dirname(__FILE__), true); //Create message bodies and embed images";

$mail->addAttachment('images/phpmailer_mini.png', 'phpmailer_mini.png'); // optional name
Expand Down

0 comments on commit ba4ece8

Please sign in to comment.