The parameters that messaging resources take are diverse enough, and beyond what is normally needed, that you can tack a lot of unintended functionality into using the usually unused stuff. We do this often with files like: messages_en_currency.properties, for example.

At 07:09 PM 2/24/03 -0500, you wrote:
Hi,

Can java.util.Currency in JDK 1.4 help you out here, perhaps in combination
with java.text.NumberFormat.getCurrencyInstance()?

Cheers,
-Steve

-----Original Message-----
From: James Childers [mailto:[EMAIL PROTECTED]
Sent: Monday, February 24, 2003 12:19 PM
To: 'Struts Users Mailing List' (E-mail)
Subject: Mixing currencies and locales


Here's a puzzler:


We need to be able to mix displaying different languages and different
currencies. For example: A user comes in with a locale of es_MX, but they
wish to view the price of their results in Yen. We have the I18N
functionality in place, but I haven't seen a way to handle this kind of
mapping. This would, of course, need to be applicable to non-western
character sets, as well.

One way that I have considered doing this is with simple resource keys, viz:

[in resources_es_MX.properties]
currency.jp=\u00A5{0}.{0}

and repeat this for each langauge/country combination. This would be
incredibly tedious, however. If there is a library or API available I would
certainly prefer to use that route.

-= J

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



LEGAL NOTICE


This electronic mail transmission and any accompanying documents contain information belonging to the sender which may be confidential and legally privileged. This information is intended only for the use of the individual or entity to whom this electronic mail transmission was sent as indicated above. If you are not the intended recipient, any disclosure, copying, distribution, or action taken in reliance on the contents of the information contained in this transmission is strictly prohibited. If you have received this transmission in error, please delete the message. Thank you



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to