[Rails] how does it know?

Jules Jacobs
Tue, 07 Feb 2006 18:41:06 -0000

If you put your files in the app/models directory, it will be
auto-loaded, IF you give the file the same name as the class.

Jules

On Tuesday, February 07, 2006, at 7:35 PM, Jacob Ezzell
wrote:
>I''m a recent Ruby/rails initiate, coming from PHP.  I''m
working my way
>through the Agile web development book, (slowly) and I ran into a wierd
>bug where the method cart.empty! wasn''t being found when I tried to
call
>it after loading my cart from the session hash.  Then I left it alone
>for a while and now it works.  ACK! :)
>
>My question is, how does ruby/rails know what files to include so it can
>find the class I''m instantiating?  I''m used to having to
include all my
>files manually with php.
>
>--
>Posted via http://www.ruby-forum.com/.
>_______________________________________________
>Rails mailing list
>Rails@lists.rubyonrails.org
>http://lists.rubyonrails.org/mailman/listinfo/rails





--
Posted with http://DevLists.com.  Sign up and save your time!