Thanks! I'm not sure I can easily resolve this problem. I am checking 3 email accounts (iCloud, Gmail and a 3rd IMAP account) on my laptop with Apple Mail, and only 1 has this problem. Every so often a message will come in as plain text, when I can clearly see it in html on my iPad or iPhone. But, that very same message might re-appear in html on my laptop when I re-launch Apple Mail on a different day. And then another message that originally appeared in html format witll miraculously show up in plain text. It must be something happening between the server and Apple Mail. Because this NEVER happens with my iCloud email account nor with my Gmail account.
I am having the exact same problem. I have 3 accounts also and the only one I have problems with is the gmail account when I am looking at it via the Apple Mail program on the mac. If I look the mail message via a web browser in gmail the html is displayed just fine. I tried the fix that I posted above, it did not fix any of the messages that I have already received but I have not had a problem with new messages since then. So I don't really know yet if the problem has gone away. If you figure anything else out please post it, as this is very annoying.
I also tried the fix that you posted (made the adjustments yesterday), but it hasn't helped. Several incoming messages today arrived in plain text format. It's not the end of the world, but it does make it more difficult to read the newsletters/messages. I'm debating making a trip to my local Genius Bar. If I learn anything, I'll be sure to post here.
defaults write com.apple.mail PreferPlainText -bool False
Which didn't seem to work.
I then tried prefixing "sudo" to the command, to make sure it wasn't a permissions issue and entered the administrator password when it asked. When I reopened Mail, the HTML formatted messages worked correctly.
sudo defaults write com.apple.mail PreferPlainText -bool False
If anyone else is still having this problem after running the command and rebuilding the mailbox envelope index, I was able to solve this by reverting to an old prefrences file from two years ago. I would also guess that rebuilding (ie deleting the file and entering settings again) would also fix this, but I did not try that as my backup worked great.
My wife is having the same problem with her new MacBook Air. She never saw the problem on the old first-gen Air running Snow Leopard.
Here's what's going on:
The messages that are having the problem are encoded as multipart/alternative. That is, they contain this in the received message:
Downstream, you'll find that boundary string whenever a new "part" begins:
Content-Type: text/plain; charset=utf-8
This begins the first part...the plain text part. On down the stream, you'll find the part header again:
Content-Type: text/html; charset=utf-8
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.=
That final <html> tag begins the bulk of the HTML code to render the graphical page. The block must end with a </html> tag to indicate the end of the block...but in this message the last line is:
<td style=3D"color: #000000; text-decoration: none; font-size: 10px; font-f=
...and that's it. Obviously, the last word should have been "Helvetica" but ***the message was cut off***. I know this because if I open the message source window for the the same message in the gmail section (not the inbox section) the end of the message looks like this:
...which is what I'd expect in a multipart MIME encoded message.
The amount of data that's missing from the end appears to be about one network packet's worth. I suspect what's going on is that mail is erroneously discarding the final packet of some mail messages.
BTW, I've taken the computer to the Genius bar, and we took the time to create a new user account and a clean mailbox and duplicated the problem there in the store. The genius was unable to recommend a solution to the problem, and suggested that I perform a reinstall-in-place of the OS. Haven't done that yet, as I consider that pretty thin gruel from the perspective of fixing the problem.
In the meantime, I'm trying Sparrow mail as an alternative mail client. So far, I haven't seen the problem using Sparrow (nor, for that matter, on OSX Snow Leopard.)
Sorry I can't be more helpful, but I'll post back in this forum if I come up with a solution. I'll follow the thread...if anybody has any ideas what might be going on please post.
Thanks for letting me know I'm not alone in all this! It's also been recommended to me to do a reinstall, but I haven't been willing to make that effort yet. In the meantime, I'll just deal with this irritating, sporadic problem.
I also have been using Sparrow as an alternate (the free version) and I have no issues whatsoever.
benalan is right, not all of the message is being read from the imap server. Not sure who's problem it is, Apple or Google. I have found a awkward work around sort of using your browser to view your gmail.
Create a mailbox on your mac, make sure it is listed under "ON MY MAC". Drag (copy) the offending message to this mailbox from your INBOX. Quit mail, restart mail, copy the offending message back to INBOX. This will cause mail to re-read the message and hopefully get it right this time around. PS. This seems to work for me, once I had to do it twice to get it right, I assume because mail read it wrong a scond time.