Is your plugin hosted on GitHub? Make sure to press the "fetch" button next to the repository field to fetch your plugin's info from GitHub rather than typing it all in.
Repository
Name
Home Page
Short description An extension to Gibberish and Rails to use it to create a multilingual web site using the around filter and Gibberish
Description Please see the full description in the "README":http://myutil.com/rdoc/gibberish_rails/ Excerpt from the README: This plugin: 1. Adds the method Gibberish.supported? to Gibberish::Localize to use it‘s map of languages to determine if a locale is supported. For example Gibberish.supported?(:en) returns true. It can be passed a string or a symbol. The previous Gibberish API returned an array of languages, but it was just so much more efficient to use the hash Gibberish had already built I added my method to the api. My Helper (6) below needs this method. 2. Redefines the Rails core method ActionView::Helpers::ActiveRecordHelper.error_message_for so messages are translates with Gibberish. 3. Overrides default error messages in ActiveReccord:Errors to include a Gibberish key. The key is blank (i.e. the entire string) so they can be automatically re-Gibberished in step 4. (next). 4. The method "add" in ActiveRecord::Errors has been overridden retranslate messages during the around filter. This become necessary because Rails 2.0.2 caches parts of messages at the class load time. 5. Redefines the method Validations.ClassMethods.validates_length_of to retranslate the messages it caches at class load up time. 6. Adds a helper method "GibberishRails.best_guess_locale" that can be used in an around filter to determine the "best guess" locale the application should be using. The highest priority is given to a parameter, followed by HTTP_ACCEPT_LANGUAGE, and finally the Gibberish default. Also, if the user wants es-mx and we support es, it will return a local of es. Here is an example usage that uses the session to cache the locale so if you are using the HTTP_ACCEPT_LANGUAGE (instead of RESTful routes), it will cache in the session instead of parsing headers every time: <pre><code> class ApplicationController < ActionController::Base # ... around_filter :use_best_guess_locale # ... # Set's the best guess language Giberish's around filter def use_best_guess_locale session[:locale] = GibberishRails.best_guess_locale(params[:locale], request.env['HTTP_ACCEPT_LANGUAGE']) if ( ! session[:locale] || params[:locale] || RAILS_ENV == 'development' ) Gibberish.use_language(session[:locale]) { yield } end end </pre></code>
Description format RDoc MarkDown Textile
License Ruby's Rails' (MIT) GPL LGPL BSD Apache Artistic PublicDomain BSD-type Free-Trial Free-but-Restricted OpenSource Proprietary Shareware Source-available-proprietary Commercial
Category Assets Controllers Internationalization Misc. Enhancements Model Rails Engines Searching and Queries Security Statistics and Logs Testing View Extensions