[horde] Translation on default folders - How?

Jan Schneider jan at horde.org
Thu Jun 26 08:34:05 UTC 2008


Zitat von Filipe Azevedo <fazevedo at netmadeira.com>:

> Jan Schneider wrote:
>> Zitat von k bah <kbah at linuxmail.org>:
>>
>>
>>> Hi,
>>>
>>> Since you can set custom names for folders like trash, sent mails,  
>>>  drafts on imp/config/prefs.php, and the Inbox name, for instance,  
>>>  depending on the language chosen from the login page, is shown   
>>> different, I would like to know if there's a clean way to set the   
>>> mentioned folders names depending on the language chosen. The   
>>> problem is Horde chooses, by default, "trash", and some IMAP  
>>> client  may choose Trash (it happened), so I chose "Trash" on   
>>> imp/config/prefs.php, but some users complain they can't find  
>>> things  (many do not speak english and are tech dummies), so it's  
>>> necessary  to keep telling them to go on "Drafts", or "sent-mail"..
>>> I would like to have all software keep using "default" names, like  
>>>  "Sent", "Drafts", "Trash", but get some translation of it shown  
>>> on  Horde. Is that possible to do without changing code, in a  
>>> clean way?  I don't want to change things so much upgrades will be  
>>> problematic.
>>>
>>
>> You can set default names in config/prefs.php, and in IMP 4.2 those  
>>  folder names will be translated by default.
>>
>> Jan.
>>
>>
> Are you sure? Because I am using the latest release versions and  
> from my experience that will only work if you set the gettext tags  
> on the folder names set on the preferences, and ofcorse lock the  
> preference... But the thing is, the IMAP folders will be created  
> attending to the users selected language, so if the user for  
> whatever reason decides to change language, he will have a whole new  
> set of IMAP folders... Not to mention the IMP protected folders  
> configuration becoming impossible to keep up with.

Correct. If you don't want this, use different default values for the  
folder names on your system. The folder names also stick once the  
users saved the folders preferences.

> I've managed to work around this issue, by adding gettext tags in  
> imp/lib/Folder.php:113 imp/lib/IMAP/Tree.php:409 imp/mailbox.php:353  
> and static/compose.php:1080

This is not necessary and would display a different folder name to the  
user than he actually has. Not good.

Jan.

-- 
Do you need professional PHP or Horde consulting?
http://horde.org/consulting/



More information about the horde mailing list