Monetary Symbols

Problems installing or using the NOP Design Free Shopping Cart that do not fit into one of the above categories.

Moderators: Koibito, Stefko, Randy

Monetary Symbols

Postby Foxglove » Thu Mar 03, 2011 10:19 pm

Hi

I've just finished getting everything working (yeehaw), but the only thing I have a problem with is the lack of £ sign in the confirmation email to the customer. I have a £ sign on all the catalogue features, checkout etc but in the email it is still a dollar sign.

Could someone put me out of my misery please?

MTIA

Fox
Foxglove
WebMaster
 
Posts: 25
Joined: Thu Mar 03, 2011 10:09 pm

Re: Monetary Symbols

Postby Koibito » Fri Mar 04, 2011 2:31 am

This is one of the first lines in nopcart.js

MonetarySymbol = '$';

Change that into:

MonetarySymbol = '£';
or
MonetarySymbol = 'GBP';

You also have to change it in your checkout cript.
John
Koibito
Site Admin / Guru
 
Posts: 918
Joined: Sun May 28, 2006 1:59 am
Location: New Jersey, USA

Re: Monetary Symbols

Postby Foxglove » Fri Mar 04, 2011 9:31 am

Hi John

Thanks for that - I'd already done the first one in the nopcart.js. It's giving me a £ for the totals on the email, but not for the items ordered.
I can't find the one in the checkout.pl. if you would be so kind as to point it out for me

Thanks

Fox
Foxglove
WebMaster
 
Posts: 25
Joined: Thu Mar 03, 2011 10:09 pm

Re: Monetary Symbols

Postby Koibito » Fri Mar 04, 2011 1:45 pm

In checkout.pl you'll find this: \$

Since the dollar sign is also used for variable names in Perl and PHP, you need to 'escape' it when you want to show just the dollar sign. That is done by adding a backslash, so Perl won't treat \$ as a variable, but will show the dollar sign instead. When you replace all the occurences of '\$' by the Pound sign (without a backslash), it will show the Pound sign instead.
John
Koibito
Site Admin / Guru
 
Posts: 918
Joined: Sun May 28, 2006 1:59 am
Location: New Jersey, USA

Re: Monetary Symbols

Postby Foxglove » Fri Mar 04, 2011 2:43 pm

Excellent - thank you!
Foxglove
WebMaster
 
Posts: 25
Joined: Thu Mar 03, 2011 10:09 pm


Return to Help: Cart / General

Who is online

Users browsing this forum: No registered users and 1 guest

cron