On 9 March 2012 19:52, AndyLikesRuby <[email protected]> wrote:
> I am getting this error message when I try to hit a certain URL:
>
> http://localhost:3000/captionfiles
>
> NoMethodError in CaptionfilesController#index
> undefined method `all' for Captionfile:Class
> app/controllers/captionfiles_controller.rb:5:in `index'
>
>    @captionfiles = Captionfile.all
>
> class Captionfile < ActiveRecord::Base

There's nothing, at first glance, wrong with your code. So can you
just confirm which version of Rails you have installed. Older (very
old!) versions didn't have ".all", you had to use ".find(:all)". But
if that's your problem, you must be on Rails 1.x, and that won't be
the last of your problems...

-- 
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 [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en.

Reply via email to