I am trying to use Globalize3 gem for model translations to Active Record i.e. internationalization for database. After going through the documentation, I was able to implement it successfully on local server in both development and production environment. But when i try to implement it on a production Server, it fails. It shows absurd behavior, i.e. it works and sometime doesn't. Trying to set locale via user input. Using this below function to set locale.
def set_language
if params[:locale]
I18n.default_locale = params[:locale]
end
redirect_to :back
end