|
Posted by Andy Hassall on 07/20/07 16:04
On Fri, 20 Jul 2007 15:58:18 +0100, "Barry Morris"
<nospam.barry_morris@btinternet.com> wrote:
>I have a problem sending e-mails using PHP and a text area as the input
>field, some characters are been changed in IE6/7 but not FireFox, is there a
>workaround for this?
>
>Tîm Personèl (note the î and è) is coming through as Tîm PersonÚl
Single character changing to double characters - first impression is that it's
being turned into UTF-8 at some point.
>[big snip]
I couldn't see any character set encoding headers in either the PHP output or
the email - what are these set to for your page?
If you want to be able to send Western European characters, the preferred
encoding would be ISO-8859-15.
If you don't set any encoding, or you submit values outside the encoding of
the page, browsers aren't entirely consistent. Some will send the characters as
HTML numeric encoded entities ("Ӓ" etc.) which may then get decoded to
double bytes by the time it reaches the email.
The key point with dealing with anything outside the simple ASCII range is
that you always have to know how your data is encoded, and make sure that
encoding is passed along correctly to the next step.
--
Andy Hassall :: andy@andyh.co.uk :: http://www.andyh.co.uk
http://www.andyhsoftware.co.uk/space :: disk and FTP usage analysis tool
[Back to original message]
|