[Home]

Summary:ASTERISK-01091: Digits in other languages
Reporter:boppen (boppen)Labels:
Date Opened:2004-02-24 13:58:31.000-0600Date Closed:2011-06-07 14:10:43
Priority:MinorRegression?No
Status:Closed/CompleteComponents:Applications/app_voicemail
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:( 0) file.c.saydigitlangfix
Description:The multi-language function doesn't work for digits, the digits in /var/lib/asterisk/sounds/digits are always used, it doesn't matter which language I sets using "SetLanguage"
Comments:By: Matteo Brancaleoni (mbrancaleoni) 2004-02-24 17:15:45.000-0600

yes, that ok, since digits (see say.c) doesn't support languages for now.
I'm working on a patch to enable italian digits, but perhaps the entire structure of say.c must be done again to easily add new languages.

By: dant (dant) 2004-02-26 17:35:31.000-0600

Could you check out the attached patch... seems far too easy a fix, what have I broken?

0 goes to fr/digits/0.gsm etc...

By: Olle Johansson (oej) 2004-02-27 07:28:09.000-0600

Couldn't we add an option to indications.conf and remove the patch in the code?
supportsenglishstylenumbering=yes|no

If yes, use the LANGUAGE setting to find sound files, if no, use the english sound files regardless of LANGUAGE setting.

Now, it works for norwegian but no other language code. We can't hack in every language code in the source, it's much easier to make it a config option.

By: Paul Cadach (pcadach) 2004-02-27 08:16:56.000-0600

It's many issues where language-specific rules must be used, i.e. "hack" for every language will be required for at least saynumber, saydigits and voicemail parts. So, those modules needs to have language API to provide interface for localization, which isn't available for now. When such API will be available, language translations of messages would be more likes as modules rather than as hacks.

By: flavour (flavour) 2004-02-29 11:20:31.000-0600

Could there be a simple function within this app which is used for basic menus (i.e. 0-9)?
This would be very easy to Internationalise & would immediately allow voicemail to be fixed.
This sounds like the quick win to get 90% of the functionality working whilst a scalable solution to the many different language variants is worked on...

By: boppen (boppen) 2004-02-29 15:44:17.000-0600

This patch works great for me!

Thanks!

By: cyb (cyb) 2004-03-03 22:41:33.000-0600

SetLanguage already works _most of the time_* for digits but it looks for the file under sounds/digits/nn (where nn=language code) instead of sounds/nn/digits , as stated above. Same goes for voicemail -- the prompts from sounds/voicemail/default/mailboxid/nn is used, not sounds/nn/voicemail/default/mailboxid/ ... Aren't we breaking with convention by doing it the sounds/nn/digits way (esp that the functionality is already built in)?

* In my case, the language-specific digits are used most of the time already in voicemail (e.g. when saying dates) but sometimes, it doesn't even try (e.g. Message X received... in this case, X is always language 'en' for some reason):

   -- Playing 'vm-message' (language 'fr')
   -- Playing 'digits/2' (language 'en')
 == Parsing '/var/spool/asterisk/voicemail/default/0000/Old/msg0001.txt':   == Parsing '/var/spool/asterisk/voicemail/default/0000/Old/msg0001.txt': Found
   -- Playing '/var/lib/asterisk/sounds/vm-received' (language 'fr')
   -- Playing '/var/lib/asterisk/sounds/digits/day-6' (language 'fr')
   -- Playing '/var/lib/asterisk/sounds/digits/mon-0' (language 'fr')
   -- Playing '/var/lib/asterisk/sounds/digits/h-10' (language 'fr')
   -- Playing '/var/lib/asterisk/sounds/digits/2' (language 'fr')

By: Olle Johansson (oej) 2004-04-15 14:07:44

Let's find a general solution to this. Check bug 0001429

By: Olle Johansson (oej) 2004-04-15 14:35:22

Patch stays in archive, discussion moves to ASTERISK-1414