Custom content localization


(Rémi Auguste) #1

Hello Discourse,

I’m trying to create a multi-languages forum based on Discourse. I’m trying to localize the custom content for the main languages that the forum will handle (english and french at first). I cannot figure out how to make the translation for all the custom content such as badge’s name, short and long descriptions, categories’ name and descriptions, tags …

I saw the topic Customize all text in Discourse but was deceived by it’s claim “customize all text”. I’m aware of /admin/customize/site_texts but it doesn’t seem to handle custom content.

Is there a way to do that in Discourse ? Without hacking the forum and loosing everything at the next update ?


(Gerhard Schlager) #2

That’s not possible at the moment. I’m recategorizing as feature request.


(Jeff Atwood) #3

Our suggestion is that you localize by category, e.g. have a Russian, French, etc category.

There is a plugin by @Simon_Cossar which sets the locale based on category that I really want to pull in and make a standard plugin that we support everywhere – we also have customers that need this.

Any news on this @erlend_sh?


(Gerhard Schlager) #4

But this plugin doesn’t solve the problem of @foloex, does it?


(Jeff Atwood) #5

The only “solution” for that is to run completely independent Discourse sites for each language at:

en.discuss.example.com
fr.discuss.example.com
sp.discuss.example.com

etc.


(Rémi Auguste) #6

The idea is to have the french and the english speaking talking to each other. if I separate my community I lose all the idea of making this forum.

However, while messing with a dummy badge (called “dummy”) I noticed that if I put ${} variables into the short and the long it of course fails but in a interesting way:
translation missing: fr.badges.dummy.long_description

So I’m just missing a way to create those string as the system is already looking for them. That doesn’t seem to apply to the badge’s name but if I can translate the short and long description that a good start :slight_smile: From what I understand /admin/customize/site_texts is just missing a form where to define new translations.