Speaking of language settings, one of the things I’m working on is getting all the RTE’s to recognize the language selected in the manager and apply it as the language choice in the RTE by default. So if a user has the manager set to Spanish then the RTE will be set to Spanish as well. I’ll have to play with it to get it to work right for front-end template variables.
Which brings me to a small dilemma. One of the things I noticed is how we’re dealing with language settings to begin with. Honestly, I think this is one area we need to clean up and rethink a bit. For starters, I feel that all language settings need to comply with the ISO standards for language codes (
http://www.loc.gov/standards/iso639-2/englangn.html). This is very important and will help greatly in allowing for other plugins, modules, and such to lookup the language setting by it’s two or three letter abbreviation (en, es, etc.) rather than looking for a whole string (english, spanish, etc.). Great help if we had this...especially since the RTE’s all use the ISO language codes. Also, I feel that when building a plugin, module, or the like, it’s a good idea to include a language directory so that it’s easier to implement language choice with a plugin or module. Many modules already have this implemented (i.e. QuickEdit). I’ll likely be rebuilding the RTE’s to include this feature...not only because it makes sense, but also because it’ll greatly reduce the amount of code going into the manager for a given RTE.
So...on that note, I think these items should be added to the to-do list for 0.9.2:
- Change language files and selection to use ISO language codes.
- Ensure all language code is in a ’lang’ directory.
- Standardize how language files and code are to be used throughout MODx.
More to come...