Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

E-Commerce Modules /

Discuss about the various e-commerce modules available:
Ecommerce, SS Shop, SilverCart and SwipeStripe
Alternatively, have a look the shared mailinglist.

Moderators: martimiz, Nicolaas, Sean, frankmullenger, biapar, Willr, Ingo, Jedateach, swaiba, simon_w

E-Commerce 0.6 beta 1 released


Reply


108 Posts   20675 Views

Avatar
Android08

Community Member, 18 Posts

25 June 2009 at 9:06pm

I found the method in payment so Payment::set_site_currency("GBP"); works but this doesn't change the $ symbol to £. Prices will show as $15.00 (GBP) I haven't been able to find where to change that.

Avatar
chrisdarl

Community Member, 33 Posts

25 June 2009 at 9:55pm

Thanks Andriod! Can't wait for the bugs in this extension to be ironed out.. great work so far guys

Avatar
TotalNet

Community Member, 181 Posts

25 June 2009 at 10:57pm

Well spotted, I guess that was moved to payment. Not a bug really although you'd want currency displayed in the catalogue too so perhaps it makes sense to make it a wider, regional setting.
as for the pound sign (don't have one on my keyboard any more) I recall seeing that asked somewhere before, I'll see if I can find it.
I'm keen to try this with 2.3.2-stable so might have a play this weekend.

Avatar
funkncreative

Community Member, 4 Posts

27 June 2009 at 3:19am

to set the currency symbol just throw this into your /ecommerce/_config.php

Currency::setCurrencySymbol('€');

and use the html code for the symbol you want

example is for EURO

Avatar
chrisdarl

Community Member, 33 Posts

28 June 2009 at 11:01pm

Using :

Payment::set_site_currency("GBP");
Currency::setCurrencySymbol('£');

changes USD -> GBP and $ -> £ on most pages, but not all areas on the checkout page (see attached "Amount" at the bottom)

Attached Files
Avatar
TotalNet

Community Member, 181 Posts

29 June 2009 at 12:56pm

That was what I was getting at when I said it should be set with a wider scope.
CurrencySymbol() belongs to ecommerce module and set_site_currency() is Payment module - I don't have the stand-alone payment module installed so can't see it currencySymbol has been implemented there as well.

Avatar
chrisdarl

Community Member, 33 Posts

29 June 2009 at 11:19pm

Also..

inside the Checkout page there's a hidden form field "Amount" that is vulnerable to people changing the value of the order total (i.e. in Firebug)

and the fix for the bug I posted previously is....
----
sapphire/core/model/fieldtypes/Currency.php - ADD :
static function getCurrencySymbol() {
   return self::$currencySymbol;
}

code/forms/OrderForm.php:70
change '$' to Currency::getCurrencySymbol()

Avatar
Thermalzombie

Community Member, 27 Posts

8 July 2009 at 11:58pm

Edited: 09/07/2009 3:15pm

Nevermind my problem is fixed but I would say that you install instructions definatly need updating.

Attached Files