tags:

views:

90

answers:

1

Actually i'm having String in UTF-8 encoded form in the mail. I want it to decode it. I use Java mimeutility.decode text. But it doesn't decode properly. Example String

=?UTF-8?B?0J/RgNC40LLQtdGC?==?UTF-8?B?0JfQtNGA0LDQstGB0YLQstGD0LnRgtC1?=

When i used

MimeUtility.decodeText("=?UTF-8?B?0J/RgNC40LLQtdGC?==?UTF-8?B?0JfQtNGA0LDQstGB0YLQstGD0LnRgtC1?=")

it yields

Привет=?UTF-8?B?0JfQtNGA0LDQstGB0YLQstGD0LnRgtC1?=

Please help me. Thanks in advance

+4  A: 

It is mime-encoded -- the "B" encoding, to be specific (rfc2047 section 4.1).

I think you can decode it using javamail javax.mail.internet.InternetHeaders or MimeUtility class.

J-16 SDiZ
This particular string decodes to "Привет Здравствуйте".
dan04