commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Leos Literak (JIRA)" <j...@apache.org>
Subject [jira] Updated: (EMAIL-95) content duplicated with UTF8 encoding
Date Fri, 05 Feb 2010 06:14:29 GMT

     [ https://issues.apache.org/jira/browse/EMAIL-95?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Leos Literak updated EMAIL-95:
------------------------------


Hmm, my fault probably. I was planning to export MimeMessage and work with it, so I tried
to run buildMessage:

        email.buildMimeMessage();
        MimeMessage message = email.getMimeMessage();
        // send the email
        String id = email.send();

when I commented this line, email arrived correctly. Could you add some checks there to avoid
this situation?

> content duplicated with UTF8 encoding
> -------------------------------------
>
>                 Key: EMAIL-95
>                 URL: https://issues.apache.org/jira/browse/EMAIL-95
>             Project: Commons Email
>          Issue Type: Bug
>    Affects Versions: 1.2
>         Environment: linux
>            Reporter: Leos Literak
>
> I tooked original sample code and it worked fine. So I modified the text, set the encoding
and ran it again - but the received email had each mime part twice.
>         HtmlEmail email = new HtmlEmail();
>         email.setHostName("smtp");
>         email.addTo("leos.literak@aaa", "Leos");
>         email.setFrom("leos.literak@aaa", "Me");
>         email.setSubject("Test email with inline image");
>         URL url = new URL("http://www.abclinuxu.cz/images/clanky/watzke/unixove-nastroje-logo.png");
>         String cid = email.embed(url, "Apache logo");
>         email.setCharset("UTF-8");
>         email.setHtmlMsg("<html>žluťoučký kůň - <img src=\"cid:" + cid
+ "\"></html>");
>         email.setTextMsg("žluťoučký kůň");
> Subject: Test email with inline image
> MIME-Version: 1.0
> Content-Type: multipart/mixed; 
> 	boundary="----=_Part_0_17764792.1265348415830"
> ------=_Part_0_17764792.1265348415830
> Content-Type: multipart/related; 
> 	boundary="----=_Part_3_12227392.1265348415896"
> ------=_Part_3_12227392.1265348415896
> Content-Type: multipart/alternative; 
> 	boundary="----=_Part_4_18450577.1265348415896"
> ------=_Part_4_18450577.1265348415896
> Content-Type: text/plain; charset=UTF-8
> Content-Transfer-Encoding: base64
> xb5sdcWlb3XEjWvDvSBrxa/FiA==
> ------=_Part_4_18450577.1265348415896
> Content-Type: text/html; charset=UTF-8
> Content-Transfer-Encoding: quoted-printable
> <html>=C5=BElu=C5=A5ou=C4=8Dk=C3=BD k=C5=AF=C5=88 - <img src=3D"cid:wddstqa=
> bqx"></html>
> ------=_Part_4_18450577.1265348415896--
> ------=_Part_3_12227392.1265348415896
> Content-Type: image/png; name="Apache logo"
> Content-Transfer-Encoding: base64
> Content-Disposition: inline; filename="Apache logo"
> Content-ID: <wddstqabqx>
> iVBORw0KGgoAAAANSUhEUgAAAEAAAABACAYAAACqaXHeAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz
> AAAG7AAABuwBHnU4NQAAABl0RVh0U29mdHdhcmUAd3d3Lmlua3NjYXBlLm9yZ5vuPBoAAAe7SURB
> 8csx12N60dP8NOIs8p6J+bS/hDjnMVyHWFVhAsgxj4I6fgsgJjch1pP2qVyhvxtMe1awQGUXwf/L
> 0ain9RibfyUJgOMcYg75ZgtQ0l8EKhtc5pkF8NJCFPF/AbzM8B8Xxxza+PCJaQAAAABJRU5ErkJg
> gg==
> ------=_Part_3_12227392.1265348415896--
> ------=_Part_0_17764792.1265348415830
> Content-Type: multipart/related; 
> 	boundary="----=_Part_1_16675983.1265348415831"
> ------=_Part_1_16675983.1265348415831
> Content-Type: multipart/alternative; 
> 	boundary="----=_Part_2_26644003.1265348415831"
> ------=_Part_2_26644003.1265348415831
> Content-Type: text/plain; charset=UTF-8
> Content-Transfer-Encoding: base64
> xb5sdcWlb3XEjWvDvSBrxa/FiA==
> ------=_Part_2_26644003.1265348415831
> Content-Type: text/html; charset=UTF-8
> Content-Transfer-Encoding: quoted-printable
> <html>=C5=BElu=C5=A5ou=C4=8Dk=C3=BD k=C5=AF=C5=88 - <img src=3D"cid:wddstqa=
> bqx"></html>
> ------=_Part_2_26644003.1265348415831--
> ------=_Part_1_16675983.1265348415831
> Content-Type: image/png; name="Apache logo"
> Content-Transfer-Encoding: base64
> Content-Disposition: inline; filename="Apache logo"
> Content-ID: <wddstqabqx>
> iVBORw0KGgoAAAANSUhEUgAAAEAAAABACAYAAACqaXHeAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz
> AAAG7AAABuwBHnU4NQAAABl0RVh0U29mdHdhcmUAd3d3Lmlua3NjYXBlLm9yZ5vuPBoAAAe7SURB
> 0ain9RibfyUJgOMcYg75ZgtQ0l8EKhtc5pkF8NJCFPF/AbzM8B8Xxxza+PCJaQAAAABJRU5ErkJg
> gg==
> ------=_Part_1_16675983.1265348415831--
> ------=_Part_0_17764792.1265348415830--
> This is a blocker for me. I would be gratefull, if you could fix it today, otherwise
I will have to abandon this library and implement its functionality myself. Thanks in advance.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message