http://www.faqs.org/rfcs/rfc2047.html describes how to encode
non-US-ASCII characters in email headers.
On Wed, 2006-03-01 at 19:26 +0530, Syed Basith (sbasith) wrote:
> Hi all,
>
> I have a perl program which accepts japanese characters in the subject
> and body, i use sendmail to send mail using perl, the body seems to be
> ok, but the subject comes as junk, is there any header encoding for
> the subject to be done when i send an email? Below is the code which i
> use for this. UNICAST reply to me
>
>
> open(EMAIL,"|/usr/lib/sendmail -t -falliupg");
> print EMAIL "From: $contact\@cisco.com>\n";
> print EMAIL "Subject: ".$subject."\n";
> print EMAIL "To: sbasith\@cisco.com\n";
> print EMAIL "Content-Type: text/plain; charset=\"iso-2022-jp
> \";encoding=\"B\"\n\n";
> print EMAIL "$details\n\n";
> print EMAIL $_;
> close( EMAIL );
>
>
> Thanks
>
> Syed Abdul Basith
>
|