ConFoo Montreal 2026: Call for Papers

Voting

: eight plus one?
(Example: nine)

The Note You're Voting On

chappy at citromail dot hu
19 years ago
In countries where there's non-us ASCII, it's a very good example, for sending mail:

mb_internal_encoding('iso-8859-2');
setlocale(LC_CTYPE, 'hu_HU');

function encode($str,$charset){
$str=mb_encode_mimeheader(trim($str),$charset, 'Q', "\n\t");
return $str;
}

print encode('the text with spec. chars: ő Ű Ő ű, ?','iso-8859-2');

It creates a 7bit string

<< Back to user notes page

To Top