Closed Bug 482198 Opened 15 years ago Closed 15 years ago

'view...plain text' shows HTML body if there is a multipart/related

Categories

(Thunderbird :: General, defect)

x86
Windows XP
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED DUPLICATE of bug 253830

People

(Reporter: bugzilla, Unassigned)

References

(Blocks 1 open bug)

Details

Attachments

(1 file)

User-Agent:       Opera/9.63 (Windows NT 5.1; U; en) Presto/2.1.1
Build Identifier: version 2.0.0.19 (20081209)

Thunderbird cannot see the plain text body created by itself, if the mail contains a HTML body with multipart/related embedded content.

Note that it does not do this with messages that have no embedded content in the HTML part - this seems to be because the plain text part and HTML part are then siblings inside the multipart/alternative. Thunderbird seems to expect to find the plain text part in the most deeply nested multipart of the email.

Note also that amazingly it works with the inversely nested output from Outlook Express (the one that puts the multipart/alternative inside the multipart/related - even though this makes it look like the embedded parts relate to the text part), because the text and HTML parts both appear in the innermost multipart.

Reproducible: Always

Steps to Reproduce:
1. Select "view - message body as - plain text".
2. Create a HTML mail with an embedded image using thunderbird and send it.
3. Open the sent item, and "file - save as - file".
4. Edit the saved file in a text editor and alter it so the contents of the plain text and HTML parts are different.
5. Now use "file - open saved message" to open it.
Actual Results:  
It shows you a textified version of the HTML part.

Expected Results:  
It should show the text/plain part.
I could observe the behaviour with Tb trunk "version 0.6+ (20050201)" on MS Win-XP SP3, with your test mail.
  
When multipart/related(text/html+image/xxx), image/xxx part is displayed as attachment, if the image/xxx part is not used(not pointed) by text/html data, or if "View/Message Body As/Plain Text". I think this is done to provide user a way to save undisplayed data to file.

When multipart/alternative[text/plain+{multipart/related(text/html+image/xxx)}] structure, if {multipart/related(text/html+image/xxx)} part is ignored by "View/Message Body As/Plain Text", Tb looses adequate way to provide user a chance to save the undisplayed image/xxx part as file.
(Please read Bug 436555 Comment #4, for current "Attachment".)

I guess;
  To avoid such issue, deepest {multipart/related(text/html+image/xxx)}
  is used as mail data, both for "View/Message Body As/" Plain Text &
  Original/Simple HTML. Then, if "View/Message Body As/Plain Text", 
  displayed string becomes "html part data converted to text".
Because multipart/alternative is for 2 versions of *same data*, this behaviour won't produce any problem, unless mail sender intentionally puts different data in text/plain part and multipart/related(text/html) part.
I also guess that above behaviour is inherited from Netscape 1, 2 etc.
Probably DUP of Bug 253830 reported in 2004.
I agree to comment #3: dupe of bug #253830.
Duping.
Status: UNCONFIRMED → RESOLVED
Closed: 15 years ago
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: