I am using following java code to send email ticket which is Html code in a mail body and also sending same ticket as attachment a html file. but some extra lines coming in the body for email clients other than Microsoft outlook like g mail etc,Here is the code,
HtmlEmail service = new HtmlEmail();
//getting body as Html content
String `strBodyText` = getSpotTicketContent(bobTicketVO,strBhLogoCid);
FileWriter fw = new FileWriter(file.getAbsoluteFile());
BufferedWriter bw = new BufferedWriter(fw);
bw.write(strBodyText);
bw.close();
URL filePath = new URL("file:///"+file.getPath());
service.attach(filePath, ""+orderType+""+dealID+".html""Baydonhill Order Ticket");
service.send();
每一件事似乎都是很好的附件和身体正常出现,除了一个额外的线来身体,比如 ------=_Part_8_20713850.1361775519720--
我正在使用 Apache common emails 1.2 和 java 1.4enter code here