Women in Technology

Hear us Roar



Article:
  Rolling with Ruby on Rails
Subject:   undefined method `scaffold' for RecipeController:Class
Date:   2008-03-12 05:08:47
From:   rsmx
Hello,
I went thru the tutorial as given in http://www.onlamp.com/pub/a/onlamp/2005/01/20/rails.html?page=3
While adding “scaffold :recipe” in recipe_controller.rb I am getting the following error.
NoMethodError in RecipeController#new
undefined method `scaffold' for RecipeController:Class


RAILS_ROOT: C:/rails/cookbook
Application Trace | Framework Trace | Full Trace
app/controllers/recipe_controller.rb:2



Please help me.

Full Threads Oldest First

Showing messages 1 through 4 of 4.

  • undefined method `scaffold' for RecipeController:Class
    2009-11-22 00:35:02  Victor Odlivak [View]

    Hello All,

    This tutorial is real old and does not work with rails 2.34 the current version. I have updated all the files to make this work including generating all the sql tables for you. Please go to
    http://converttolinux.com/ruby.shtml

    Enjoy!
  • undefined method `scaffold' for RecipeController:Class
    2008-06-27 07:52:00  wonger [View]

    Did you ever find the answer to this? I am getting the same error.
    • undefined method `scaffold' for RecipeController:Class
      2008-07-16 00:30:01  thinhbk [View]

      with rail version 2.0 we can't use scaffold :recipe like this, it will generate error.
      The easiest way to do is use ruby eclipse plugin, it will generate for us.
      • undefined method `scaffold' for RecipeController:Class
        2009-10-30 11:37:44  Vijay A [View]

        I also faced the same problem.
        The tutorial presented here : http://oreilly.com/pub/a/ruby/archive/rails.html?page=4 seems to be out of date.

        I would suggest going through this new tutorial
        http://fairleads.blogspot.com/2007/12/rails-20-and-scaffolding-step-by-step.html