ISO encoding of subject in mail?

From: Date: Tue, 29 Mar 2005 13:55:46 +0000
Subject: ISO encoding of subject in mail?
Groups: php.general 
Request: Send a blank email to php-general+get-211778@lists.php.net to get a copy of this message
Hi I´d like to encode the subject in mails generated and sent by PHP, so Danish letters like æ,ø and å can be used too... like this: Subject: Problemer med =?ISO-8859-1?Q?f=E6llesdrev_m=2Em=2E?= I can´t seem to find a proper function for this? I´ve tried with encode(), htmlentities() and htmlspecialchars(): $subject = htmlentities($subject, ENT_QUOTES, "ISO-8859-1"); which gives: Subject: ADVARSEL: Få IP adresser tilbage And it´s not converted by the mailclients. I´d like to solve this since the mailserver at work complaints if the subject is not encoded: X-Amavis-Alert: BAD HEADER Non-encoded 8-bit data (char E5 hex) in message header 'Subject': Subject: ADVARSEL: F\345 IP adresser ti... Any tips/ideas? -- Med venlig hilsen / best regards ComX Networks A/S Kim Madsen Systemudvikler/systemdeveloper

« previous php.general (#211778) next »