Re: Mail () problem with some letters

From: Date: Mon, 28 Apr 2003 12:22:56 +0000
Subject: Re: Mail () problem with some letters
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-145517@lists.php.net to get a copy of this message
Hello, On 04/27/2003 08:50 PM, Websteve wrote:
I have a small problem with my forms. I send it through the mail function $text = $firstname." ".$lastname." ."Firstname ".$firstname."\nLastname: ".$lastname."\...... and so on; mail("mail@mailadress.com","Contactform by $firstname $lastname",$text); When the user has sent the form everything works well and I receive all my informations. But only letters like 'ö' or 'ü' or 'ä' and some more were not displayed correctly. Ie. Instead of 'ö' my mailprogram shows me ö What do I have to do to send the form correctly.
You need to use q-encoding in message headers like Subject to send non 7 bit ASCII that is accepted by e-mail gateways. You may want to try this class that encodes your headers properly as you need: http://www.phpclasses.org/mimemessage -- Regards, Manuel Lemos

« previous php.general (#145517) next »