Add support for Rails 3.0 AND above
Fix tests

- i18n.available_locales produces an array sorted alphabetically ...
- ...The JS follow the same order