Jump to content

Pound Symbol in Subject - mailalerts.php


evolution.x

Recommended Posts

Hi,

 

I am trying to show the order total in the subject of the new order email.

 

So far i have this:

 

mailalerts.php - PS 1.4.9.0 - Line 171

 

$subject = $this->l('Order', false, (int)$id_lang).' - '.sprintf('%06d', $order->id).' - '.sprintf('%c156').sprintf($order->total_paid, $currency);

 

Output from above: [shop Name] Order - 000999 - 10.99

 

Output Wanted: [shop Name] Order - 000999 - £10.99

 

This shows me the order amount but i cannot get the pound symbol to show?

 

As you can see i have tried ASCII %c156 but this does not work?

 

Any help on this would be great!

Link to comment
Share on other sites

Hi

 

Subject must be send in this case in correct mime type encoding with utf8 charset for example.

 

I am really not sure that the mail client will detect UTF8 and create correct mime type

but I would try a

utf8_encode($subject).

or

$subject = '=?UTF-8?B?'.base64_encode(utf8_encode($subject));

 

or

$subject = '=?UTF-8?B?'.base64_encode($subject);

 

Good luck

Edited by math_php (see edit history)
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...