Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8311017
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T19:40:12+00:00 2026-06-08T19:40:12+00:00

I have with an application in french. When I run my application an I

  • 0

I have with an application in french. When I run my application an I test a form I have this message “Email : should look like an email address.”, in english. When I save my “fr.yml” I have this message : “Email : ne semble pas être une adresse email”, in french, like I want. It appear only for authlogic’s fields and it was working, with same code, last month.

This is by application.rb :

  require File.expand_path('../boot', __FILE__)

  # Pick the frameworks you want:
  require "active_record/railtie"
  require "action_controller/railtie"
  require "action_mailer/railtie"
  require "active_resource/railtie"
  require "sprockets/railtie"
  # require "rails/test_unit/railtie"

  if defined?(Bundler)
    # If you precompile assets before deploying to production, use this line
    Bundler.require(*Rails.groups(:assets => %w(development test)))
    # If you want your assets lazily compiled in production, use this line
    # Bundler.require(:default, :assets, Rails.env)
  end

  module Onopia
    class Application < Rails::Application
      # Settings in config/environments/* take precedence over those specified here.
      # Application configuration should go into files in config/initializers
      # -- all .rb files in that directory are automatically loaded.

      # Custom directories with classes and modules you want to be autoloadable.
      # config.autoload_paths += %W(#{config.root}/extras)

      # Only load the plugins named here, in the order given (default is alphabetical).
      # :all can be used as a placeholder for all plugins not explicitly named.
      # config.plugins = [ :exception_notification, :ssl_requirement, :all ]

      # Activate observers that should always be running.
      # config.active_record.observers = :cacher, :garbage_collector, :forum_observer

      # Set Time.zone default to the specified zone and make Active Record auto-convert to this zone.
      # Run "rake -D time" for a list of tasks for finding time zone names. Default is UTC.
      # config.time_zone = 'Central Time (US & Canada)'

      # The default locale is :en and all translations from config/locales/*.rb,yml are auto loaded.
      # config.i18n.load_path += Dir[Rails.root.join('my', 'locales', '*.{rb,yml}').to_s]
      config.i18n.default_locale = :fr

      # Configure the default encoding used in templates for Ruby 1.9.
      config.encoding = "utf-8"

      # Configure sensitive parameters which will be filtered from the log file.
      config.filter_parameters += [:password]

      # Enable the asset pipeline
      config.assets.enabled = true

      # Version of your assets, change this if you want to expire all your assets
      config.assets.version = '1.1'

      # Configure generators values. Many other options are available,
      # be sure to check the documentation.
      #config.generators do |g|
      #  g.test_framework :rspec, :fixture => false
      #end

      config.action_mailer.default_url_options = { :host => 'localhost:3000' }
      config.assets.initialize_on_precompile = false
    end

    if defined?(Bundler)
      Bundler.require(:default, :assets, Rails.env)
    end
  end

This is my gem list :

    actionmailer (3.2.2)
    actionpack (3.2.2)
    activeadmin (0.4.3)
    activemodel (3.2.2)
    activerecord (3.2.2)
    activeresource (3.2.2)
    activesupport (3.2.2)
    addressable (2.2.7)
    archive-tar-minitar (0.5.2)
    arel (3.0.2)
    authlogic (3.1.0)
    autotest-rails (4.1.1)
    bcrypt-ruby (3.0.1)
    blankslate (2.1.2.4)
    bourbon (1.4.0)
    builder (3.0.0)
    bundler (1.1.2)
    capybara (1.1.2)
    capybara-firebug (0.0.10)
    capybara-webkit (0.9.0)
    childprocess (0.3.1)
    coderay (1.0.6)
    coffee-rails (3.2.2)
    coffee-script (2.2.0)
    coffee-script-source (1.2.0)
    columnize (0.3.6)
    cucumber (1.1.9)
    cucumber-rails (1.2.1)
    database_cleaner (0.7.0)
    devise (2.0.4)
    diff-lcs (1.1.3)
    email_spec (1.2.1)
    erubis (2.7.0)
    execjs (1.3.0)
    factory_girl (2.3.2)
    factory_girl_rails (1.4.0)
    fastercsv (1.5.4)
    ffi (1.0.11)
    formtastic (2.1.1)
    galetahub-simple_captcha (0.1.3)
    gherkin (2.9.3)
    has_scope (0.5.1)
    heroku (2.24.0)
    hike (1.2.1)
    i18n (0.6.0)
    inherited_resources (1.3.1)
    jbuilder (0.4.0)
    journey (1.0.3)
    jquery-rails (2.0.2)
    json (1.6.6)
    kaminari (0.13.0)
    launchy (2.0.5)
    linecache19 (0.5.12)
    mail (2.4.4)
    meta_search (1.1.3)
    metaclass (0.0.1)
    method_source (0.7.1)
    mime-types (1.18)
    mocha (0.10.0)
    multi_json (1.0.4)
    netrc (0.7.1)
    nifty-generators (0.4.6)
    nokogiri (1.5.2)
    orm_adapter (0.0.7)
    pg (0.13.2)
    pickle (0.4.10)
    polyamorous (0.5.0)
    polyglot (0.3.3)
    prawn (0.8.4)
    prawn-core (0.8.4)
    prawn-layout (0.8.4)
    prawn-security (0.8.4)
    pry-nav (0.2.0)
    pry-remote (0.1.1)
    rack (1.4.1)
    rack-cache (1.2)
    rack-ssl (1.3.2)
    rack-test (0.6.1)
    rails (3.2.2)
    railties (3.2.2)
    rake (0.9.2.2)
    rdoc (3.12)
    responders (0.9.1)
    rest-client (1.6.7)
    rspec (2.8.0)
    rspec-core (2.8.0)
    rspec-expectations (2.8.0)
    rspec-mocks (2.8.0)
    rspec-rails (2.8.1)
    ruby-debug-base19 (0.11.25)
    ruby-debug19 (0.11.6)
    ruby_core_source (0.1.5)
    rubyzip (0.9.7)
    sass (3.1.15)
    sass-rails (3.2.5)
    selenium-webdriver (2.20.0)
    shoulda-context (1.0.0)
    shoulda-matchers (1.0.0)
    simple_form (2.0.1)
    simplecov (0.5.4)
    simplecov-html (0.5.3)
    simplecov-rcov (0.2.3)
    slop (2.4.4)
    spork (0.8.5)
    sprockets (2.1.2)
    sqlite3 (1.3.5)
    term-ansicolor (1.0.7)
    thor (0.14.6)
    tilt (1.3.3)
    treetop (1.4.10)
    tzinfo (0.3.33)
    uglifier (1.2.4)
    warden (1.1.1)
    xpath (0.1.4)
    ZenTest (4.5.0)

And this is my fr.yml:

    # French translations for Ruby on Rails
    # by Christian Lescuyer (christian@flyingcoders.com)
    # contributors:
    # - Sebastien Grosjean - ZenCocoon.com
    # - Bruno Michel - http://github.com/nono
    # - Tsutomu Kuroda - http://github.com/kuroda (t-kuroda@oiax.jp)

    fr:
      date:
        formats:
          default: "%d/%m/%Y"
          short: "%e %b"
          long: "%e %B %Y"
        day_names:
          - lundi
          - mardi
          - mercredi
          - jeudi
          - vendredi
          - samedi
          - dimanche
        abbr_day_names:
          - lun
          - mar
          - mer
          - jeu
          - ven
          - sam
          - dim
        month_names:
          - ~
          - janvier
          - février
          - mars
          - avril
          - mai
          - juin
          - juillet
          - août
          - septembre
          - octobre
          - novembre
          - décembre
        abbr_month_names:
          - ~
          - jan.
          - fév.
          - mar.
          - avr.
          - mai
          - juin
          - juil.
          - août
          - sept.
          - oct.
          - nov.
          - déc.
        order:
          - :day
          - :month
          - :year

      time:
        formats:
          default: "%d %B %Y %H:%M:%S"
          short: "%d %b %H:%M"
          long: "%A %d %B %Y %H:%M"
        am: 'am'
        pm: 'pm'

      datetime:
        distance_in_words:
          half_a_minute: "une demi-minute"
          less_than_x_seconds:
            zero: "moins d'une seconde"
            one: "moins d'une seconde"
            other: "moins de %{count} secondes"
          x_seconds:
            one: "1 seconde"
            other: "%{count} secondes"
          less_than_x_minutes:
            zero: "moins d'une minute"
            one: "moins d'une minute"
            other: "moins de %{count} minutes"
          x_minutes:
            one: "1 minute"
            other: "%{count} minutes"
          about_x_hours:
            one: "environ une heure"
            other: "environ %{count} heures"
          x_days:
            one: "1 jour"
            other: "%{count} jours"
          about_x_months:
            one: "environ un mois"
            other: "environ %{count} mois"
          x_months:
            one: "1 mois"
            other: "%{count} mois"
          about_x_years:
            one: "environ un an"
            other: "environ %{count} ans"
          over_x_years:
            one: "plus d'un an"
            other: "plus de %{count} ans"
          almost_x_years:
            one: "presqu'un an"
            other: "presque %{count} ans"
        prompts:
          year: "Année"
          month: "Mois"
          day: "Jour"
          hour: "Heure"
          minute: "Minute"
          second: "Seconde"

      number:
        format:
          separator: ","
          delimiter: " "
          precision: 3
          significant: false
          strip_insignificant_zeros: false
        currency:
          format:
            format: "%n %u"
            unit: "€"
            separator: ","
            delimiter: " "
            precision: 2
            significant: false
            strip_insignificant_zeros: false
        percentage:
          format:
            delimiter: ""
        precision:
          format:
            delimiter: ""
        human:
          format:
            delimiter: ""
            precision: 2
            significant: true
            strip_insignificant_zeros: true
          storage_units:
            format: "%n %u"
            units:
              byte:
                one: "octet"
                other: "octets"
              kb: "ko"
              mb: "Mo"
              gb: "Go"
              tb: "To"
          decimal_units:
            format: "%n %u"
            units:
              unit: ""
              thousand: "millier"
              million: "million"
              billion: "milliard"
              trillion: "billion"
              quadrillion: "million de milliards"

      support:
        array:
          words_connector: ", "
          two_words_connector: " et "
          last_word_connector: " et "
        select:
          prompt: "Veuillez sélectionner"

      helpers:
        select:
          prompt: "Veuillez sélectionner"
        submit:
          create: "Créer un %{model}"
          update: "Modifier ce %{model}"
          submit: "Enregistrer ce %{model}"

      attributes:
        created_at: "Créé le"
        updated_at: "Modifié le"

      errors:
        format: "%{attribute} : %{message}"
        messages: &errors_messages
          inclusion: "n'est pas inclus(e) dans la liste"
          exclusion: "n'est pas disponible"
          invalid: "n'est pas valide"
          confirmation: "ne concorde pas avec la confirmation"
          accepted: "doit être accepté(e)"
          empty: "doit être rempli(e)"
          blank: "doit être rempli(e)"
          too_long: "est trop long (pas plus de %{count} caractères)"
          too_short: "est trop court (au moins %{count} caractères)"
          wrong_length: "ne fait pas la bonne longueur (doit comporter %{count} caractères)"
          not_a_number: "n'est pas un nombre"
          not_an_integer: "doit être un nombre entier"
          greater_than: "doit être supérieur à %{count}"
          greater_than_or_equal_to: "doit être supérieur ou égal à %{count}"
          equal_to: "doit être égal à %{count}"
          less_than: "doit être inférieur à %{count}"
          less_than_or_equal_to: "doit être inférieur ou égal à %{count}"
          odd: "doit être impair"
          even: "doit être pair"
        template: &errors_template
          header:
            one: "Impossible d'enregistrer ce %{model} : 1 erreur"
            other: "Impossible d'enregistrer ce %{model} : %{count} erreurs"
          body: "Veuillez vérifier les champs suivants : "

      activerecord:
        errors:
          messages:
            taken: "n'est pas disponible"
            record_invalid: "La validation a échoué : %{errors}"
            <<: *errors_messages
          template:
            <<: *errors_template
          full_messages:
            format: "%{attribute} %{message}"

        attributes:
          models:
            user: Utilisateur
            account: "Compte"
            bank: "Banque"
          user:
            username: Pseudo
            email: Email
            password: Mot de passe
          account:
            login: "Identifiant"
            password: "Mot de passe"
            account_type_id: "Type"

      home:
        successfully_updated: "Votre mot de passe a été modifié"
        index:
          submit: "Valider"
          remember: 'Me rappeler mon not de passe'

      authlogic:
        error_messages:
          login_blank: "doit être rempli(e)"
          login_not_found: "n'est pas valide"
          login_invalid: "doit contenir uniquement des lettres, des nombres, des espaces, et .-_@ s'il vous plaît."
          consecutive_failed_logins_limit_exceeded: La limit de tentatives de connexion consectuives a été dépassée. Le compte à été désactivé.
          email_invalid: ne semble pas être une adresse email
          password_blank: "doit être rempli(e)"
          password_invalid: "n'est pas valide"
          not_active: "Votre compte n'est pas actif"
          not_confirmed: "Votre compte n'est pas confirmé"
          not_approved: "Votre compte n'est pas approuvé"
          no_authentication_details: "Vous n'avez pas fournis les details pour vous authentifier."
        models:
          user: "Utilisateur"
          user_session: "Session utilisateur"
        attributes:
          user_session:
            username: Pseudo
            login: Login
            email: Email
            password: "Mot de passe"
            remember_me: "se souvenir de moi"

      simple_captcha:
        label: "Veuillez saisir le code ci-dessous:"
        message:
          user: "le code de sécurité n'est pas valide"

Can you help me?

Thanks.

UPDATE :
I put a breakpoint in the file “authlogic/acts_as_authentic/email.rb” at this function :

    "validates_format_of_email_field_options" 

and when I test I18n.t(‘error_messages.email_invalid’) I have this message :

    translation missing: en.authlogic.error_messages.email_invalid 

so, authlogic take the default message. When I try this :

    Onopia::Application.config.i18n.default_locale 

I have :

    :fr

I don’t understand. Maybe than authlogic is loaded before my locales???

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-08T19:40:14+00:00Added an answer on June 8, 2026 at 7:40 pm

    In application.rb, also set the current locale:

    i18n.config.default_locale = :fr
    i18n.config.locale = :fr
    

    Just don’t ask me why 🙂

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a java application which has a GUI in both English and French,
I have ASP.NET MVC 3 application having resource files in english and french .
I have this form in a Django application In Firefox it works as charm,
I have to develop the application into Four(4) languages (English, French, Italic, Spanish). So,
I have application with needs to have access to some sensitive data(in this case
I have an application that runs on an English-US ASP.NET server (English installation of
I have a (rather dirty) datasource (excel) that looks like this: ID | Name
Hi I submitted my first application to the appStore http://itunes.apple.com/at/app/section-control/id343824642?mt=8 This displays English as
I have an app that requires 2 languages, English and French. I have already
I have one form in a Windows application as per below image: I try

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.