Rolling with Ruby on Rails
Subject:   Scaffold command
Date:   2006-03-22 14:21:30
From:   claudiaG
I am working on Mac OS X. I did a tutorial for Ruby on Rails specifically for Mac OS X. In it, we typed the following command after creating the tables in the database to get the basic CRUD functions for the web interface:
script/generate scaffold <model name> <controller name>

In this tutorial, it is suggested to write the following line inside the controller file;
scaffold :<model name>

Which way is better? Does it matter?

If I don't put the scaffold command inside the controller file, after what changes do I have to run the script/generate scaffold ... command? For example, when I modified a table in the db, the change wasn't shown in the web page until I ran the command. I guess I don't really understand exactly what "scaffold" does.


1 to 1 of 1
  1. Curt Hibbs photo Scaffold command
    2006-03-22 20:04:51  Curt Hibbs | O'Reilly AuthorO'Reilly Blogger [View]

    • Scaffold command
      2006-03-23 14:31:31  claudiaG [View]

1 to 1 of 1