There is built in support for this in soon to be released 2.2 (Rails
edge). You can read about it here
http://iain.nl/2008/09/translating-activerecord/
/Erik
On 2 Sep, 16:03, polarapfel
<tobias.weisse...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
wrote:> Hi everybody,
>
> I am getting involved deeper and deeper with Rails development and
> basically I love it. However, as Rails was born in the English
> language world, I find it rather demanding to develop with other end
> user languages in mind. One of the issues I''m having is with
> validation error messages.
>
> I know how to create custom error messages for validation errors in
> the models. However, these messages get appended behind the validated
> field name which isn''t necessarily human readable or in the
> application end user language.
>
> How do I get rid of model field names in the validation error
> messages?
>
> Just to be very clear this is an example:
>
> Say there is a field ''name'' in the table
''users'' and I validate ''name''
> in ''User'' I get validation error messages like these:
>
> ''Name can''t be empty.''
>
> I can only replace the ''can''t be empty.'' part.
How Do I get rid if
> ''Name'' in the error message?
>
> Thanks,
>
> Tobias W.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Ruby on Rails: Talk" group.
To post to this group, send email to
rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---