views:

45

answers:

1

Hi everyone,

I try to figure out how I can localize the error item name in my rails application which appear when a user sign's up with uncorrect datas... I figured out how to override the messages but not the names of the messages like ("password", "login", "email", ...)

de:
  activerecord:
    errors:
      models:
        user:
          attributes:
            password_confirmation:
              blank: ""
            password:
              confirmation: ""
              blank:  ""
              too_short: ""
            login:
              taken: ""
              blank: ""
              too_short: ""
            email:
              taken: ""
              blank: ""
              too_short: ""
              invalid: ""
      template:
        header: ""
        body: ""

Thanks Markus

+1  A: 

From the i18n guide this should work:

de:
  activerecord:
    attributes:
      user:
        login: Anmeldung
Shadwell