# Error messages

**URL:** <https://www.ruby-forum.com/t/error-messages/189450>\
**Category:** Rails\
**Created:** [June 1, 2010, 10:15am UTC](https://www.ruby-forum.com/t/error-messages/189450 "2010-06-01T10:15:20Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Mlle](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/eada6e/32.png) [@Mlle](https://www.ruby-forum.com/u/Mlle)\
**Post date:** [June 1, 2010, 10:15am UTC](https://www.ruby-forum.com/t/error-messages/189450/1 "2010-06-01T10:15:20Z")

</div>

I use validates\_presence\_of in my model and I use the yml file to have  
the error message translate into:

Veuillez vérifier les champs suivants :

```
* Material doit être rempli(e)

```

But how can I translate the name of the attribute that is blank? I  
want to translate Material also into French.

---

<div class="post-metadata">

**Author:** ![Mlle](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/eada6e/32.png) [@Mlle](https://www.ruby-forum.com/u/Mlle)\
**Post date:** [June 1, 2010, 11:34am UTC](https://www.ruby-forum.com/t/error-messages/189450/2 "2010-06-01T11:34:22Z")

</div>

On Jun 1, 9:14 am, Mlle [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> I use validates\_presence\_of in my model and I use the yml file to have  
> the error message translate into:
> 
> Veuillez vérifier les champs suivants :
> 
> ```
> * Material doit être rempli(e)
> 
> ```
> 
> But how can I translate the name of the attribute that is blank? I  
> want to translate Material also into French.

> **[Rails Internationalization (I18n) API — Ruby on Rails Guides](https://guides.rubyonrails.org/i18n.html#translations-for-active-record-models)**
>
> Rails Internationalization (I18n) APIThe Ruby I18n (shorthand for internationalization) gem which is shipped with Ruby on Rails (starting from Rails 2.2) provides an easy-to-use and extensible framework for translating your application to a single...

Fred
