Facebook  Twitter 

SMFHacks.com

+-

SMFHacks.com

+- User Information

Welcome, Guest.
Please login or register.
 
 
 
Forgot your password?

+- Forum Stats

Members
Total Members: 11833
Latest: playwyourlifenotme
New This Month: 1
New This Week: 1
New Today: 1
Stats
Total Posts: 42303
Total Topics: 7379
Most Online Today: 31
Most Online Ever: 2482
(April 09, 2011, 07:02:45 pm)
Users Online
Members: 0
Guests: 30
Total: 30

Author Topic: Currency issues  (Read 15391 times)

0 Members and 1 Guest are viewing this topic.

Offline gibbs

  • Member
  • *
  • Posts: 33
  • Using SMF Gallery and Classifieds
    • View Profile
Currency issues
« on: August 08, 2008, 07:12:25 am »
Dear support,

I am in the UK and wish my default currency to be in Pounds Sterling.

I have set the currency in the SMF Classified Settings to "Pounds Sterling" but that does not seem to make it default throughout the rest of the site.

Examples are:

1. When a user lists a new item for sale, it defaults to "U.S. Dollars." in the picklist.

2. When a user views a listing that has been placed in Pounds Sterling, it shows the currency sign as a square (�) rather than a Pound sign ().

That is all I have found so far on this subject. I'll look out for more. If you have any suggestions on how I can make it default completely to pounds sterling, that would be most appreciated.

Cheers.

Offline vkot

  • Full Member
  • ***
  • Posts: 136
    • View Profile
Re: Currency issues
« Reply #1 on: August 08, 2008, 12:08:27 pm »
In classifieds.template.php change every instance of
Code: [Select]
<option value="GBP">',$txt['class_cur_GBP'],'</option>to
Code: [Select]
<option selected value="GBP">',$txt['class_cur_GBP'],'</option>
...or change the order of the option values in the select object (put <option value="GBP">',$txt['class_cur_GBP'],'</option> at the top)

Offline gibbs

  • Member
  • *
  • Posts: 33
  • Using SMF Gallery and Classifieds
    • View Profile
Re: Currency issues
« Reply #2 on: August 08, 2008, 04:37:18 pm »
And again, thanks for the help. much appreciated.  :)

Offline SMFHacks

  • Administrator
  • Hero Member
  • *****
  • Posts: 16037
    • View Profile
Re: Currency issues
« Reply #3 on: August 08, 2008, 06:45:26 pm »
Hold up on using that it may cause some issues with paypal payments if you change the values.
Get your Forum Ranked! at https://www.forumrankings.net - find out how your forum compares with others!

Like What I do? Support me at https://www.patreon.com/vbgamer45/

Offline vkot

  • Full Member
  • ***
  • Posts: 136
    • View Profile
Re: Currency issues
« Reply #4 on: August 09, 2008, 01:44:02 am »
SMFHacks, you are talking about the change of the order?
What will happen to paypal payments? A wrong currency will be passed to paypal?

Offline SMFHacks

  • Administrator
  • Hero Member
  • *****
  • Posts: 16037
    • View Profile
Re: Currency issues
« Reply #5 on: August 09, 2008, 08:40:49 am »
If you change the value="GBP"  it may not work.
Get your Forum Ranked! at https://www.forumrankings.net - find out how your forum compares with others!

Like What I do? Support me at https://www.patreon.com/vbgamer45/

Offline gibbs

  • Member
  • *
  • Posts: 33
  • Using SMF Gallery and Classifieds
    • View Profile
Re: Currency issues
« Reply #6 on: August 11, 2008, 10:47:33 am »
So is there a better way to go about it please?

Offline SMFHacks

  • Administrator
  • Hero Member
  • *****
  • Posts: 16037
    • View Profile
Re: Currency issues
« Reply #7 on: August 11, 2008, 07:20:19 pm »
1. Will have a fix for that.

2. What version of the classifieds are you running. I do have it defined for GBP
Code: [Select]
function formatprice($price,$currency)
{
if ($currency == 'USD')
return  '$' .  number_format($price, 2, '.', '');
else if ($currency == 'GBP')
return  '' .  number_format($price, 2, '.', '');
elseif ($currency == 'CAD')
return  '$' .  number_format($price, 2, '.', '');
elseif ($currency == 'AUD')
return  '$' .  number_format($price, 2, '.', '');
else
return $price . ' ' . $currency;

}
Get your Forum Ranked! at https://www.forumrankings.net - find out how your forum compares with others!

Like What I do? Support me at https://www.patreon.com/vbgamer45/

Offline vkot

  • Full Member
  • ***
  • Posts: 136
    • View Profile
Re: Currency issues
« Reply #8 on: August 12, 2008, 05:33:23 am »
SMFhacks,

I am not changing any values. In my first solution I just add selected to the option tag. This only tells to the select box what is the default value.

In my second solution, a problem could exist only if you refer to the values with their number, for example: document.cprofile.currency.options[2].text

Anyway, I see that you have a first option:
Code: [Select]
<option value="', $modSettings['class_set_currency'], '">', $modSettings['class_set_currency'], '</option>in some of the selects. Maybe this should be added to all.


Offline SMFHacks

  • Administrator
  • Hero Member
  • *****
  • Posts: 16037
    • View Profile
Re: Currency issues
« Reply #9 on: August 12, 2008, 06:59:56 pm »
Added a fix like that.
But sill need a response about

2. What version of the classifieds are you running? I do have it defined for GBP so it should display the right character. Unless it is a character set issue.
Get your Forum Ranked! at https://www.forumrankings.net - find out how your forum compares with others!

Like What I do? Support me at https://www.patreon.com/vbgamer45/

Offline gibbs

  • Member
  • *
  • Posts: 33
  • Using SMF Gallery and Classifieds
    • View Profile
Re: Currency issues
« Reply #10 on: August 14, 2008, 11:05:15 am »
Sorry for the delay.

I have SMF version 1.1.5 and running Classifieds 1.2.4

Offline SMFHacks

  • Administrator
  • Hero Member
  • *****
  • Posts: 16037
    • View Profile
Re: Currency issues
« Reply #11 on: August 14, 2008, 08:11:15 pm »
1.2.6
!Fixed default currency to show the one in settings when adding an auction/listing
!Fixed possible pound sterling character display issue.
Get your Forum Ranked! at https://www.forumrankings.net - find out how your forum compares with others!

Like What I do? Support me at https://www.patreon.com/vbgamer45/

Offline gibbs

  • Member
  • *
  • Posts: 33
  • Using SMF Gallery and Classifieds
    • View Profile
Re: Currency issues
« Reply #12 on: August 18, 2008, 10:51:15 am »
Worked a treat. Thanks!

 

Related Topics

  Subject / Started by Replies Last post
5 Replies
8493 Views
Last post July 02, 2008, 02:32:47 am
by vkot
Currency

Started by BRC MODELS « 1 2 » Support

17 Replies
13278 Views
Last post February 27, 2013, 11:03:56 am
by luiswr
1 Replies
2268 Views
Last post December 06, 2010, 07:29:19 pm
by SMFHacks
2 Replies
2262 Views
Last post June 17, 2012, 12:35:38 pm
by Maloxan
9 Replies
4776 Views
Last post June 18, 2012, 02:09:08 pm
by Maloxan

+- Recent Topics

Trying to access array offset on value of type null by SMFHacks
June 30, 2022, 03:58:54 pm

SMF forum by davejo
June 27, 2022, 01:16:25 am

Quick-moderation checkboxes by davejo
June 22, 2022, 09:27:24 am

Add option to Main Menu bar by Shades
June 21, 2022, 12:23:00 am

Logo and Category? by SMFHacks
June 12, 2022, 03:43:31 pm

prettyurls - TroubleShooting.wiki by GhostHunting
June 12, 2022, 02:52:57 pm

[Mod]Modification Update Version Checker by SMFHacks
June 06, 2022, 09:25:39 pm

Profile Gallery Link by SMFHacks
June 02, 2022, 05:17:45 pm

SMF Store 5.0 Beta Errors - Trying to access array offset on value of type null by Michael Vail
June 01, 2022, 12:48:48 pm

Upgrade Issues? by SMFHacks
May 30, 2022, 06:24:03 pm

Powered by EzPortal