You are not logged in or registered. Please login or register to use the full functionality of BayernForum.com

New BBCode: currencyformat

Announcements for new BayernForum.com features
 

New BBCode: currencyformat

Postby MUTU » Mon May 01, 2017 8:34 am

I've added a new BBCode that allows money to be formatted according to the regional settings set in the operating system.

Example usage: [currencyformat=EUR]€1,000,000[/currencyformat]
30GB free cloud storage. Click here for the referral.
User avatar
MUTU
Site Admin & EURO 2016 Prediction Game Winner
Site Admin & EURO 2016 Prediction Game Winner
 
Years of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membership
 
Posts: 30544
Joined: Mon Aug 14, 2006 11:00 pm
Location: L-Imqabba, Malta
National Flag:
Malta
Has thanked: 5302 times
Been thanked: 7928 times
Gender: Male
BayernForum.com fan club: Active member
BayernForum.com donator: Yes

Re: New BBCode: currencyformat

Postby MUTU » Mon May 01, 2017 8:34 am

Result:

I'm using it in our player profile page but it can be used in any post.
30GB free cloud storage. Click here for the referral.
User avatar
MUTU
Site Admin & EURO 2016 Prediction Game Winner
Site Admin & EURO 2016 Prediction Game Winner
 
Years of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membership
 
Posts: 30544
Joined: Mon Aug 14, 2006 11:00 pm
Location: L-Imqabba, Malta
National Flag:
Malta
Has thanked: 5302 times
Been thanked: 7928 times
Gender: Male
BayernForum.com fan club: Active member
BayernForum.com donator: Yes

Re: New BBCode: currencyformat

Postby FCBayernMunchen » Mon May 01, 2017 10:17 am

I'm confused, probably because the example used is my currency. So if I write the example you used, will it appear in GBP for UK users? Or do I have to change the EUR in the example?


Sent from my iPhone using Tapatalk
Super Bayern! Super Bayern! Hey! Hey!
User avatar
FCBayernMunchen
Moderator
 
Years of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membership
 
Posts: 30526
Joined: Tue Aug 05, 2008 12:54 pm
Location: Malta
National Flag:
Malta
Has thanked: 8521 times
Been thanked: 7149 times
Gender: Male
BayernForum.com fan club: Active member
BayernForum.com donator: Yes

Re: New BBCode: currencyformat

Postby Firefox1234 » Mon May 01, 2017 5:53 pm

MUTU always one step ahead of us

While we're still chilling in the 3rd/4th dimension he's working four or five levels above us
Welcome to the Allianz Arena....

Lasciate ogne speranza, voi ch'intrate
User avatar
Firefox1234
Moderator
 
Years of membershipYears of membershipYears of membershipYears of membershipYears of membership
 
Posts: 13975
Joined: Wed May 09, 2012 1:42 am
Location: USA
National Flag:
Kenya
Has thanked: 4628 times
Been thanked: 2948 times
Gender: Male
BayernForum.com fan club: Active member
BayernForum.com donator: Yes

Re: New BBCode: currencyformat

Postby MUTU » Mon May 01, 2017 7:47 pm

FCBayernMunchen wrote:I'm confused, probably because the example used is my currency. So if I write the example you used, will it appear in GBP for UK users? Or do I have to change the EUR in the example?


Sent from my iPhone using Tapatalk

For GBP you can do

It's not that confusing. Different cultures display currency differently.

For example, one may display 1 million euros as €1,000,000 (I believe this is used in the United Kingdom)
A different culture may display it as €1.000.000
Another culture may show 1.000.000 € (I believe in Germany and Italy they use this format)

These settings are defined in your OS. This BBCode uses Javascript I wrote to solve this issue, and users would be able to see prices formatted in the way their culture does.
30GB free cloud storage. Click here for the referral.
User avatar
MUTU
Site Admin & EURO 2016 Prediction Game Winner
Site Admin & EURO 2016 Prediction Game Winner
 
Years of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membership
 
Posts: 30544
Joined: Mon Aug 14, 2006 11:00 pm
Location: L-Imqabba, Malta
National Flag:
Malta
Has thanked: 5302 times
Been thanked: 7928 times
Gender: Male
BayernForum.com fan club: Active member
BayernForum.com donator: Yes

Re: New BBCode: currencyformat

Postby FCBayernMunchen » Mon May 01, 2017 8:46 pm

Ah ok, I get it now. I thought it was something different.
Super Bayern! Super Bayern! Hey! Hey!
User avatar
FCBayernMunchen
Moderator
 
Years of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membershipYears of membership
 
Posts: 30526
Joined: Tue Aug 05, 2008 12:54 pm
Location: Malta
National Flag:
Malta
Has thanked: 8521 times
Been thanked: 7149 times
Gender: Male
BayernForum.com fan club: Active member
BayernForum.com donator: Yes


Return to Site Announcements

Who is online

Users browsing this forum: No registered users and 1 guest