Hi, I''m pretty new on ruby and rubyonrails, so if this sounds too simple just answer :) ... in fact I need some directions ... I''m already with an usefull login system (oh!:), but I''d like to do things with the right approach .... About validation: After reading some mailing-list posts and rubyonrails documents I''ve just realized that the validation works just when in fact persisting my record (creation, update, etc.) ... but I`d like to validate form submission, is there some "native" way on rubyonrails to validate the form submission? About messages and I18N : - Is there any field (related) messages support? - How are you implementing multi-language applications? I was thinking on delay the message translation to the view (and so I could use gettext or anything like that) but this solves just one part of the problem, is localization already supported or is someone working on this? thanks + Samuel G. Mota + smota-UD6lNx2AZ21Wk0Htik3J/w@public.gmane.org + 55 (11) 4417 7093 + Business Application Dpt. + Netset Serviços em Tecnologia + a Hypercom Company + http://www.hypercom.com
Hello Samuel, On Tue, 28 Dec 2004 12:50:37 -0300, Samuel Mota <SMota-UD6lNx2AZ21Wk0Htik3J/w@public.gmane.org> wrote:> > About validation: > After reading some mailing-list posts and rubyonrails documents I''ve just realized that the > validation works just when in fact persisting my record (creation, update, etc.) ... but I`d like to > validate form submission, is there some "native" way on rubyonrails to validate the form > submission?Do you mean on the "creation" of your record ? You can put :on => :create in your validation macros so it only checks on creation of a new object, if what you want is to validate only on creation. Check "validates_format_of" for example, in the API documentation of ruby on rails, it might help. Cheers /B -- Bruno Mattarollo <bruno.mattarollo-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>