Change private messaging "inbox" tab to japanese

edited April 2008 in Vanilla 1.0 Help
I am trying to get my forum up and running, but having some problems. I am using the private messaging add-on, but I want to change on the tab where it says "Inbox" into Japanese. Since "private messages" is an add-on, you can not change the language in the conf/language.php right? I have all the japanese plugins and database set up to utf-8 and such, and everything else is working great, I just need how I should go about changing it in the add-on without mucking up the way it works? I know that I can really mess up the inner-workings if I just start sticking Japanese into the configuration files! Any thoughts?

Comments

  • i think you can overwrite the definition in your language file
  • Thats just it. It is an add-on, so there is no definition in the language file. It is in the extension configuration file. I just need to know where to change what.
  • find the lines in the extension's default.php that say something like Context->Dictionary->AddDefinition..........

    cut / paste those to the japanese language file, and translate it. It will override whatever the extension had before.

    P.S. you may need to clear your browser's cache
  • Sweet! Thanks Boss! I will giver a try!
  • edited March 2008
    In the default.php of private messages extention, there are two different "Inbox" values (see below), and I tried copying the first and the last lines into the conf/language.php but neither of them worked.
    Am I missing something?
    Thanks for your help.

    $Context->Dictionary['PrivateMessagesTab'] = 'Inbox';

    $Context->Dictionary['SendPrivateMessage'] = 'Send private message';

    $Context->Dictionary['PrivateMessages'] = 'Private Messages';

    $Context->Dictionary['Inbox'] = 'Inbox';
  • edited March 2008
    I also tried putting just
    $Context->Dictionary['Inbox'] = 'myvalue';

    and then I tried just
    $Context->Dictionary['PrivateMessagesTab'] = 'myvalue';

    then I tried both
    $Context->Dictionary['Inbox'] = 'myvalue';
    $Context->Dictionary['PrivateMessagesTab'] = 'myvalue';

    I tried these combinations in the English language file, the Japanese language file, and also in the conf/language file.
    I erased the browsers cache and even switched browsers and still no change.

    I then tried
    $Context->Dictionary['PrivateMessagesTab'] = 'inbox';
    $Context->Dictionary['Inbox'] = 'myvalue';

    and that didn't work either.

    Any other ideas?
    Thanks
  • edited March 2008
    be sure to delete those lines in the default.php in the extension's folder, so then the lines are ONLY in your language files; otherwise the extension's definitions override the language's.
  • Ah! Thank you. I will try it right now!
  • It worked! Thanks a bunch. Now I know how to do all my extensions!
  • most of them shouldn't have it hard-coded in the extension's php (there's a different, newer way that's always overridden by language definitions)
  • Do you mean the Private messaging add-on is old, and that it should be able to be overridden by the language files?
    Now that I think about it, yeah, shouldn't the conf/language file override everything? I had to put the translated files in the Japanese language files, why don't they work in the conf/language file?
  • yes, it uses the old way of adding definitions; there's a newer way that is automatically overridden by language definitions.
This discussion has been closed.