RE: [PHP] URGENT: function mail()

From: Date: Wed, 25 Jul 2001 09:57:44 +0000
Subject: RE: [PHP] URGENT: function mail()
Groups: php.general 
Request: Send a blank email to php-general+get-59517@lists.php.net to get a copy of this message
Feeling a little guilty for not being that helpful (rfc's aren't that easy to use sometimes) From the top of my head Two types of encoding based on the RFC B (Base64) Q (Quoted?) so for funky foreign text, non ascii would be something like $subject= base64_encode ($subject); $subject= "=?ISO-8859-2?B?". $subject. "=?="; for normal ascii range //Replace space with =20 $subject = ereg_replace (" ", "=20", $subject); $subject = ""=?ISO-8859-2?Q?". $subject ."=?="; As i've said off the top of my head, read the spec carefully for exact output. you should get the general idea from the above though. -----Original Message----- From: Lawrence.Sheed@dfait-maeci.gc.ca [mailto:Lawrence.Sheed@dfait-maeci.gc.ca] Sent: July 25, 2001 5:45 PM To: gernot.veit@webconomy.net; php-general@lists.php.net Subject: RE: [PHP] URGENT: function mail() Have a look at the internet - google is good for this http://www.imc.org/mail-i18n.html#MIME Internationalized text and names appear in both parts of Internet mail messages: in the headers, and in the body of the message. RFC 2047 covers how to use international characters in some parts of non-MIME headers, such as addresses and subject headers. RFC 2231 extends the concepts in RFC 2047 to cover MIME parameter values, and also specifies a method for using language tagging for international characters in these headers. RFC 2046 describes how to specify the charset for each part of the body of the message so, you're looking for RFC2047 http://www.imc.org/rfc2047 In that it describes how to do it something like =?iso-8859-2q?this is some text?= would probably work for you, but you'll need to encode the characters correctly according to the rfc. cheers, Lawrence. -----Original Message----- From: Gernot [mailto:gernot.veit@webconomy.net] Sent: July 25, 2001 4:53 PM To: php-general@lists.php.net Subject: [PHP] URGENT: function mail() i've the following problem.... i know how to set the charset in the header of a mail using the php mail-function. but i also need to set it for the subject (iso-8859-2) i hope someone can help me -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net For additional commands, e-mail: php-general-help@lists.php.net To contact the list administrators, e-mail: php-list-admin@lists.php.net -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net For additional commands, e-mail: php-general-help@lists.php.net To contact the list administrators, e-mail: php-list-admin@lists.php.net

« previous php.general (#59517) next »