Jump to content

Recommended Posts

It seems that sometimes when I use the pound symbol (£) I get a  symbol prepended to it, but when this happens I can't seem to prevent it - I can't figure out what's making this happen - Has this happened to anyone else before?

I haven't coded anything to specifically use UTF-8, although, this pound sign is being used in the content of an e-mail that is being generated by my script, but sent using the phpmailer class - So, I guess there's the possibility that either that class is encoding it's output in UTF-8, or it's down to my mail client?

 

Will have a quick poke around in the phpmailer class, though I had this issue the other day on another project, where certain parts of the site would display the symbol fine, and other places I would get the same problem, but I wasn't doing anything out of the ordinary to cause the issue...

 

EDIT: No, phpmailer is using iso-8859-1 encoding too.

Just me typing it into my script - That's why I'm having difficulty understanding why this is happening!

<?php
//...
$content = "Your quote:\r\n\r\n".
           "Width: $width metres\r\n".
           "Length: $length metres\r\n".
           "Location: $location\r\n".
           "Surface: $s[name]\r\n\r\n".
           "Quote: GBP £$total\r\n".
           "Ref: $ref";
//...
?>

I'm not sure how PHP files are interpreted yet in terms of "high ascii" characters. This could be locale or server related. Does Apache have AddDefaultCharset? What about the e-mail programs? Is PHP Mailer explicitly setting a character set for the receiving end?

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.