Re: Validating DateHelpers date_select

Duane Johnson
Thu, 26 May 2005 16:42:49 -0000

> Wow... where would I put this?

I would put it in some file such as "activerecord_extensions.rb" (or
something that makes sense to you) and keep it in the lib folder of
your rails application.  Then add this to your config/environment.rb
file (at the end):

require ''activerecord_extensions.rb''

Rails will know how to find it automatically, so there''s no need to
specify the directory.  Requiring it like this in your environment.rb
file will guarantee that all parts of your application have access to
it (i.e. it guarantees that the modification to ActiveRecord will
occur before your models are auto-included).

Duane Johnson
(canadaduane)

_______________________________________________
Rails mailing list
Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org