Jesper Rønn-Jensen
2006-Aug-13 13:28 UTC
[Rails] Announcement: Really simple localization plugin
I needed something simpler than Globalize and GLoc to localize my Rails application into Danish. I packed it into this plugin. Feel free to use it. Languages available: Spanish, German, Swedish, Danish, and ("Swedish Chef" for the fun of it) Plugin available at http://visitjesper.homeip.net/plugins/ IMPORTANT: Plugin directory likely to move to more appropriate location anytime The goal is to have a dead simple plugin for one-language (non-english) Rails applications. Many of the existing localization/internationalization plugins are too big for this and hard to get started with. Just dump this plugin in /vendor/plugins/, set your language and off you go. Unlike the more advanced plugins, you don''t have to translate anything in your view files. Just use the standard Rails commands you''re used to. The simple approach also makes limits. Make sure you understand them to decide if this plugin is right for you. ===What it does This plugin modifies the following most used helpers for Rails * Sets UTF-8 content-type HTTP header * Sets UTF-8 connection to database * Localized monthnames on date_select etc. (but not changing the order of Y-M-D) * Localized ActiveRecord errors (and error headings) * Localized distance_of_time_in_words * Localized to_currency (but not changing the order of unit/currency) * Simple pluralization also available in the lang-file (but currently only used for pluralizing "error"=>"errors" in local language) * Changes standard Rails methods. In this way, there''s no tedious rewrite of localization functions in your view files * Languages available: Spanish, German, Swedish, Danish, and ("Swedish Chef" for the fun of it) Read more in the README file of the project. If you want to help out, I''d really like you to translate into more languages. See more under TODO in the README file. Also, since this is my first plulgin, any feedback is welcome. There is probably something I can do smarter.. As a side note: Is there somebody here who want''s to translate it into "Pirate speak" (world Talk like a pirate day is coming soon...) -- Jesper R?nn-Jensen http://justaddwater.dk/ (weblog) -------------- next part -------------- An HTML attachment was scrubbed... URL: http://wrath.rubyonrails.org/pipermail/rails/attachments/20060813/cc533a51/attachment.html
Reasonably Related Threads
- i18n friendly, plugable Rails Core
- distance_of_time_in_words hardcoded strings should be separated for easier localization
- DateHelpers .. don' display.. ?
- How to do a time-stratified case-crossover analysis for air pollution data?
- How to do a time-stratified case-crossover analysis for air pollution data? Unformatted text-version, with an additional note