Re [ic] Locale question

Joachim Leidinger interchange-users@lists.akopia.com
Tue Jul 3 11:35:00 2001


Stefano Nota wrote:
> 
> --code:
> 
> [item-price]<br>
> [if scratch mv_locale eq it_IT]
>         [tmp ita][item-price noformat=1][/tmp]
>         [setlocale it_IT]
>                 [currency convert=1][scratch ita][/currency]

try           [currency][scratch ita][/currency]

>         [setlocale]
> [/if]
> [if scratch mv_locale eq en_US]
>                 [tmp eng][item-price noformat=1][/tmp]
>                 [setlocale en_US][currency]

this [currency] is wrong. Delete it.

>                         [currency convert=1][scratch eng][/currency][/currency]

Try only [currency][scratch eng][/currency]


>                 [setlocale]
> [/if]

Summary: 
Your code make no sense for me. Because if your setting is right, you
dont need the if construct like above.

Try 

TEST: The locale is [scratch mv_locale] and the price is [item-price]
<BR>

in your page first and switch the language. It will display the price
and the currecny symbol correctly.
A usefull hint is...install the construct demo in your server too and
see what happen, if you choose another language.
Do you know, how to change the language on the fly?
Switch the language: 	<A HREF="[area
href="process/locale/en_US/page/mypage"]">English</A>&nbsp;
			<A HREF="[area href="process/locale/it_IT/page/mypage"]">Italiano</A>
			<A HREF="[area href="process/locale/eur_EUR/page/mypage"]">Italiano
EURO</A>


> --Locale.TXT
> code            en_US   de_DE  fr_FR  it_IT      eur_EUR spa_SPA
> 
> PriceDivide 1.18154 0.5409 0.1632 0.000516457 1 1.18154
> 
> currency_symbol $ DM            FF      Lit             EURO
> 
> default         0         0       0       0          1         0
> frac_digits 2         2       2     0          2
> mon_decimal_point .   ,      ,      ,          ,
> mon_thousand_sep    . .
> mon_thousands_sep , , . . .
> p_cs_precedes 1   1 1
> p_sep_by_space   1 1 1
> 
> --Catalog.cfg
> Locale          eur_EUR LC_CTYPE eur_EUR

I'm missing

Locale     it_IT .....
Locale      en_US .....
and so on... (don't forget to restart the IC Server) ...in your
catalog.cfg.

ciao

Joachim

-- 
-------------<BPA FreeBsd>----------------------------------------------
Hans-Joachim Leidinger          black point arts Internet Solutions GmbH
email: jojo@blackpoint.de       FAX  : +49 0209-398265
http://www.bpaserver.net