← Back to team overview

c2c-oerpscenario team mailing list archive

[Bug 644325] Re: In Lead shows HTML from email rather than plain text

 

I am running with 6.0 trunk as of 21/12/2010

Hello

I am posting this comment to this existing issue, as I have noticed
another related issue re showing html in the opportunity rather than
plain text.

I received an email from ABI Research, I have attached the relevant
source below.

I have attached a sreenshot showing how the text is incorrectly
rendered.

Received: from database5 (database5.abiresearch.com [172.16.1.249])
	by linux-smtp.abiresearch.com (Postfix) with ESMTP id 0AC8641E45B
	for <sales@xxxxxxxxxxx>; Fri, 17 Dec 2010 17:38:24 -0500 (EST)
Message-ID: <26909612.1292625504097.JavaMail.mailer@database5>
From: cgallen@xxxxxxxxxxxxxxxxxxxx
Reply-To: cgallen@xxxxxxxxxxxxxxxxxxxx
To: sales@xxxxxxxxxxx
Subject: New Research Cluster: Cloud
Mime-Version: 1.0
Content-Type: text/html; charset=utf-8
Content-Transfer-Encoding: quoted-printable
Date: Fri, 17 Dec 2010 17:38:24 -0500 (EST)

<!-- rid:65835344 --><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitio=
nal//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd";>

<html xmlns=3D"http://www.w3.org/1999/xhtml";>
<head>
    <link rel=3D"stylesheet" type=3D"text/css" href=3D'http://www.abiresear=
ch.com/images/email/email.css?65835344'/>
    <title></title>

</head>
<body>
   =20
    <div id=3D"divContent"><table cellpadding=3D"20" width=3D"100%" style=
=3D"background-color:rgb(238, 243, 251)">

<tbody><tr>

<td align=3D"center">

<table cellspacing=3D"0" cellpadding=3D"0" border=3D"0" width=3D"700">

<tbody><tr>

<td align=3D"right" colspan=3D"3"><a href=3D"http://www.abiresearch.com/";><=
img alt=3D"ABI Research" src=3D"http://data.abiresearch.com/eblasts/cluster=
s/abi-logo.png" style=3D"border-top-width:0px;border-right-width:0px;border=
-bottom-width:0px;border-left-width:0px;border-style:initial;border-color:i=
nitial" /></a></td>

</tr>

<tr>

<td colspan=3D"3"><img height=3D"50" width=3D"700" src=3D"http://data.abire=
search.com/eblasts/clusters/cluster-head_01.jpg" alt=3D"" /></td>

</tr>

<tr>

<td rowspan=3D"2"><img height=3D"93" width=3D"17" src=3D"http://data.abires=
earch.com/eblasts/clusters/cluster-head_02.jpg" alt=3D"" /></td>
<td valign=3D"top" height=3D"40" width=3D"473" style=3D"background-color:rg=
b(147, 159, 183);color:white;font-size:24px;font-weight:bold;font-family:ve=
rdana, arial, sans-serif"><a href=3D"http://www.abiresearch.com/products/cl=
uster/Cloud_Research_Cluster" style=3D"color:white;text-decoration:none">Cl=
oud</a></td>
<td rowspan=3D"2"><img height=3D"93" width=3D"210" src=3D"http://data.abire=
search.com/eblasts/clusters/cluster-head_04.jpg" alt=3D"" /></td>

</tr>

<tr>

<td><img height=3D"53" width=3D"473" src=3D"http://data.abiresearch.com/ebl=
asts/clusters/cluster-head_05.jpg" alt=3D"" /></td>

</tr>

</tbody></table>

<table cellpadding=3D"10" width=3D"700" style=3D"text-align:left;font-famil=
y:verdana, arial, sans-serif;font-size:11px;background-color:white">

<tbody><tr>

<td>

=09=09=09=09=09A Research Cluster is a collection of reports and other deli=
verables with a common theme that spans multiple Research Services. Cluster=
s are an ideal way to augment the coverage of our traditional research subs=
criptions.

=09=09=09=09</td>
<td valign=3D"top" width=3D"200" rowspan=3D"7">

<h2 style=3D"color:rgb(40, 63, 110);font-size:14px;margin-top:0px;margin-ri=
ght:0px;margin-bottom:3px;margin-left:0px">Contact Sales</h2>

<p>For more information and research purchasing options, please contact the=
 sales representative closest to your location.</p>

<p>North America:<br />

<a href=3D"mailto:nasales@xxxxxxxxxxxxxxx"; title=3D"[GMCP] Compose a new ma=
il to NAsales@xxxxxxxxxxxxxxx" rel=3D"noreferrer" style=3D"color:rgb(40, 63=
, 110)">NAsales@xxxxxxxxxxxxxxx</a>

</p>

<p>Europe:<br />

<a href=3D"mailto:eusales@xxxxxxxxxxxxxxx"; title=3D"[GMCP] Compose a new ma=
il to EUsales@xxxxxxxxxxxxxxx" rel=3D"noreferrer" style=3D"color:rgb(40, 63=
, 110)">EUsales@xxxxxxxxxxxxxxx</a>

</p>

<p>Asia-Pacific:<br />

<a href=3D"mailto:apsales@xxxxxxxxxxxxxxx"; title=3D"[GMCP] Compose a new ma=
il to APsales@xxxxxxxxxxxxxxx" rel=3D"noreferrer" style=3D"color:rgb(40, 63=
, 110)">APsales@xxxxxxxxxxxxxxx</a>

</p>

</td>

</tr>

<tr>

<td style=3D"font-weight:bold;color:rgb(40, 63, 110);font-size:14px">

=09=09=09=09=09The <a href=3D"http://www.abiresearch.com/products/cluster/C=
loud_Research_Cluster" style=3D"color:rgb(40, 63, 110);text-decoration:unde=
rline">Cloud Research Cluster</a> Includes:

=09=09=09=09</td>

</tr>

<tr>

<td>

<h2 style=3D"margin-top:0px;margin-right:0px;margin-bottom:3px;margin-left:=
10px;font-size:12px">

<a href=3D"http://www.abiresearch.com/research/1004999-Consumer+Cloud+Compu=
ting" style=3D"color:rgb(40, 63, 110);text-decoration:none">Consumer Cloud =
Computing</a>

</h2>

<p style=3D"margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:1=
0px">Web-based Applications for E-Mail, Document Storage/Sharing, PC Protec=
tion, and Backup</p>

</td>

</tr>

<tr>

<td>

<h2 style=3D"margin-top:0px;margin-right:0px;margin-bottom:3px;margin-left:=
10px;font-size:12px">

<a href=3D"http://www.abiresearch.com/research/1005202-Consumer+Cloud+Compu=
ting+Survey+2010+" style=3D"color:rgb(40, 63, 110);text-decoration:none">Co=
nsumer Cloud Computing Survey 2010 </a>

</h2>

<p style=3D"margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:1=
0px">E-Mail, Online Data Storage, Photo Storage and Sharing, Anti-Virus/Ant=
i-Spam, and PC Backup</p>

</td>

</tr>

<tr>

<td>

<h2 style=3D"margin-top:0px;margin-right:0px;margin-bottom:3px;margin-left:=
10px;font-size:12px">

<a href=3D"http://www.abiresearch.com/research/1004608-Enterprise+Mobile+Cl=
oud+Computing" style=3D"color:rgb(40, 63, 110);text-decoration:none">Enterp=
rise Mobile Cloud Computing</a>

</h2>

<p style=3D"margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:1=
0px">Cloud Services, Mobile Devices, and the IT Supply Chain Analysis </p>

</td>

</tr>

<tr>

<td>

<h2 style=3D"margin-top:0px;margin-right:0px;margin-bottom:3px;margin-left:=
10px;font-size:12px">

<a href=3D"http://www.abiresearch.com/research/1003385-Mobile+Cloud+Applica=
tions" style=3D"color:rgb(40, 63, 110);text-decoration:none">Mobile Cloud A=
pplications</a>

</h2>

<p style=3D"margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:1=
0px">Widgets and the Apps Dilemma for Smartphones, Netbooks, Media Tablets,=
 and Connected Mobile Devices</p>

</td>

</tr>

<tr>

<td>

<h2 style=3D"margin-top:0px;margin-right:0px;margin-bottom:3px;margin-left:=
10px;font-size:12px">

<a href=3D"http://www.abiresearch.com/research/1003591-Gaming+in+the+Cloud"=
 style=3D"color:rgb(40, 63, 110);text-decoration:none">Gaming in the Cloud<=
/a>

</h2>

<p style=3D"margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:1=
0px">Online Gaming for PCs, Video Game Consoles, and Connected Devices</p>

</td>

</tr>

</tbody></table>

<table cellspacing=3D"0" cellpadding=3D"20" width=3D"700" style=3D"backgrou=
nd-color:white;font-family:verdana, arial, sans-serif;font-size:11px">

<tbody><tr>

<td colspan=3D"4">

<hr />

</td>

</tr>

<tr>

<td width=3D"25%" valign=3D"top"><b style=3D"color:rgb(40, 63, 110)">SCOTTS=
DALE</b>

<br />

<br />

=09=09=09=09=0914555 N Scottsdale Rd.<br />

=09=09=09=09=09Suite 150<br />

=09=09=09=09=09Scottsdale, AZ 85254<br />

<br />

=09=09=09=09=09Tel: +1.516.624.2500<br />

=09=09=09=09=09Fax: +1.516.624.2501<br />

</td>
<td width=3D"25%" valign=3D"top"><b style=3D"color:rgb(40, 63, 110)">NEW YO=
RK</b>

<br />

<br />

=09=09=09=09=09501 Seventh Ave.<br />

=09=09=09=09=09Suite 205A<br />

=09=09=09=09=09New York, NY 10018<br />

<br />

=09=09=09=09=09249 South Street<br />

=09=09=09=09=09Oyster Bay, NY 11771<br />

<br />

=09=09=09=09=09Tel: +1.516.624.2500<br />

=09=09=09=09=09Fax: +1.516.624.2501<br />

<br />

</td>
<td width=3D"25%" valign=3D"top"><b style=3D"color:rgb(40, 63, 110)">LONDON=
</b>

<br />

<br />

=09=09=09=09=094-6 Staple Inn<br />

=09=09=09=09=093rd Floor, Suite B<br />

=09=09=09=09=09Holborn<br />

=09=09=09=09=09London, WC1V 7HQ<br />

<br />

=09=09=09=09=09Fax:<br />+44.(0).203.326.0141<br />

<br />

=09=09=09=09=09Sales &amp; Client Relations:<br /> +44.(0).203.326.0140<br =
/>

<br />

=09=09=09=09=09Media Relations:<br /> +44.(0).203.326.0142<br />

<br />

</td>
<td width=3D"25%" valign=3D"top"><b style=3D"color:rgb(40, 63, 110)">SINGAP=
ORE</b>

<br />

<br />

=09=09=09=09=0910 Anson Road<br />

=09=09=09=09=09#33-11 Int'l Plaza<br />

=09=09=09=09=09Singapore 079903<br />

<br />

=09=09=09=09=09Tel: +65.6592.0290<br />

=09=09=09=09=09Fax: +65.6223.9509<br />

</td>

</tr>

</tbody></table>

<img height=3D"20" width=3D"700" src=3D"http://data.abiresearch.com/eblasts=
/clusters/bottom.jpg" alt=3D"" /></td>

</tr>

</tbody></table>
?=E2=80=8B</div>
    <div id=3D"divE" style=3D"text-align:center; margin-top:20px; color:Gra=
y; font-size:10px; font-family: Verdana, Arial, sans-serif">You have receiv=
ed this message at the e-mail address: sales@xxxxxxxxxxx</div>
    <div id=3D"divUL" style=3D"text-align:center; font-size:10px; font-fami=
ly: Verdana, Arial, sans-serif">If you no longer want to receive our Resear=
ch Alerts e-mails, you may unsubscribe from these mailings by clicking <a s=
tyle=3D'font-size:10px' target=3D_blank href=3D'http://www.abiresearch.com/=
pages/AccountService/unsubscribe.jsp?email=3Dsales@xxxxxxxxxxx&rid=3D658353=
44'>here</a></div>

</body>
</html>
<!-- -EOF- -->

-- 
You received this bug notification because you are a member of C2C
OERPScenario, which is subscribed to the OpenERP Project Group.
https://bugs.launchpad.net/bugs/644325

Title:
  In Lead shows HTML from email rather than plain text

Status in OpenObject Addons Modules:
  Fix Released

Bug description:
  With this mail the first part is HTML only, no plain text version, and the footer in plain text only no html. Mail source is attached

This type of mail is not being handled very well by mailgate. The crm module will automatically convert HTML to plain text .. but only if that HTML is part of a multipart email message. The example you gave does not have multiparts, just a "Content-Type: 
text/html" header. The CRM mail import does not detect this needs to be run through the HTML to text converter, and thus you get the email with HTML tags.

The fix for this is not simply to do the same as the multipart decoding, as the headers are named differently when the message is not multipart.

The key things are these headers in the email:

Content-Transfer-Encoding: quoted-printable
Content-Type: text/html;
	charset="UTF-8"

<FONT face=3D"Default Sans Serif,Verdana,Arial,Helvetica,sans-serif" [...]