0
|
1 --TEST--
|
|
2 Bug #8386 HTML body not correctly encoded if attachments present
|
|
3 --SKIPIF--
|
|
4 --FILE--
|
|
5 <?php
|
|
6 $eol = "\n#";
|
|
7 include("Mail/mime.php");
|
|
8 $encoder = new Mail_mime(array('eol'=>$eol));
|
|
9 $encoder->setTXTBody('test');
|
|
10 $encoder->setHTMLBody('<b>test</b>');
|
|
11 $encoder->addAttachment('Just a test', 'application/octet-stream', 'test.txt', false);
|
|
12 $body = $encoder->get();
|
|
13 if (strpos($body, '--' . $eol . '--=')){
|
|
14 print("FAILED\n");
|
|
15 print("Single delimiter() between 2 parts found.\n");
|
|
16 print($body);
|
|
17 }else{
|
|
18 print("OK");
|
|
19 }
|
|
20 ?>
|
|
21 --EXPECT--
|
|
22 OK
|