A question about Content-type & encoding# Java - 爪哇娇娃
c*y
1 楼
I am writing an email client. There are several lines like this in the program:
message.getContent()
Then for one email I got an exception which will abort the operation, the exception
is:
java.io.UnsupportedEncodingException: X-UNKNOWN
I looked at the email mesage, and found out in the headers of the email:
Content-Type: TEXT/PLAIN; charset=X-UNKNOWN
obviously it was the charset's problem..
How can solve this problem?
Thanks.
message.getContent()
Then for one email I got an exception which will abort the operation, the exception
is:
java.io.UnsupportedEncodingException: X-UNKNOWN
I looked at the email mesage, and found out in the headers of the email:
Content-Type: TEXT/PLAIN; charset=X-UNKNOWN
obviously it was the charset's problem..
How can solve this problem?
Thanks.