Closed pomartel closed 11 years ago
Unfortunatelyt, it doesn't seem to support any kind of fallbacks. The easiest (and really hacky) way I've found is to simply add the key to each translation, setting the value to the english string, and updating as the translators have time.
Oh wait, tinyMCEPopup.getLang
lets you specify a default value, which is supposed to be used if the translated version can't be found. The plugin does this, but only for the bits in the JS. In the HTML, we use {#uploadimage_dlg.input}
, which I found somewhere, and gets replaced with the right values. Not sure if that bit can take a default value as well.
The {#uploadimage_dlg.input}
bits gets replaced in a function called translate
, deep in the tiny_mce_src.js
file from tinymce-rails
(line 14052). Doesn't look promising for a fallback there.
Would be great if that works. It would also be good if it could default to the english translations files if the files are missing. I was a bit horrified when I found out that if a translation file is missing, tinymce won't load at all and throw a JS error.
Here is the spanish translation for the plugin. By the way, I didn't take the time to read the tinymce I18n documentation but do you know if there is a way to default missing translations to english? This way, it doesn't look so awful if you add features in the future and a translation is missing.