# Scaffold in Rails 2

**URL:** <https://www.ruby-forum.com/t/scaffold-in-rails-2/119215>\
**Category:** Rails\
**Created:** [November 5, 2007, 1:05am UTC](https://www.ruby-forum.com/t/scaffold-in-rails-2/119215 "2007-11-05T01:05:08Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Arash](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/da6949/32.png) [@Arash](https://www.ruby-forum.com/u/Arash)\
**Post date:** [November 5, 2007, 1:05am UTC](https://www.ruby-forum.com/t/scaffold-in-rails-2/119215/1 "2007-11-05T01:05:08Z")

</div>

Hi,  
I am trying rails 2 and the dynamic scaffolding does not work. I  
wonder if the syntax changed or what?

---

<div class="post-metadata">

**Author:** ![Arash](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/da6949/32.png) [@Arash](https://www.ruby-forum.com/u/Arash)\
**Post date:** [November 5, 2007, 1:29am UTC](https://www.ruby-forum.com/t/scaffold-in-rails-2/119215/2 "2007-11-05T01:29:40Z")

</div>

On Nov 4, 2007, at 4:04 PM, Arash wrote:

> Hi,  
> I am trying rails 2 and the dynamic scaffolding does not work. I  
> wonder if the syntax changed or what?

It’s been pulled:

[dev.rubyonrails.org/changeset/7429](http://dev.rubyonrails.org/changeset/7429)

---

<div class="post-metadata">

**Author:** ![Arash](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/da6949/32.png) [@Arash](https://www.ruby-forum.com/u/Arash)\
**Post date:** [November 5, 2007, 2:19am UTC](https://www.ruby-forum.com/t/scaffold-in-rails-2/119215/3 "2007-11-05T02:19:56Z")

</div>

You can still get the same behavior by using the scaffold generator  
included with rails, only the ActionController#scaffold method has  
been removed. If you wanted scaffolding for the Product model, try  
running script/generate Product. If you run script/generate with no  
options, it will give you a quick help with examples. This is better  
anyway as it creates the controller with all of the relevant code  
included allowing you to see and change it.

Hope this helps.

-Bill

---

<div class="post-metadata">

**Author:** ![Arash](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/da6949/32.png) [@Arash](https://www.ruby-forum.com/u/Arash)\
**Post date:** [November 5, 2007, 10:36am UTC](https://www.ruby-forum.com/t/scaffold-in-rails-2/119215/4 "2007-11-05T10:36:26Z")

</div>

William P. wrote:

> You can still get the same behavior by using the scaffold generator  
> included with rails, only the ActionController#scaffold method has  
> been removed. If you wanted scaffolding for the Product model, try  
> running script/generate Product. If you run script/generate with no  
> options, it will give you a quick help with examples. This is better  
> anyway as it creates the controller with all of the relevant code  
> included allowing you to see and change it.
> 
> Hope this helps.
> 
> -Bill

As far as i can tell, scaffold hasn’t been removed as such - instead its  
functionalty has been replaced with that of the old scaffold\_resource,  
which is used to make a RESTful scaffold. In other words, the scaffold  
has been changed to be RESTful by default. This is going to break a lot  
of tutorials i think. Bill, have you experienced otherwise?

---

<div class="post-metadata">

**Author:** ![Arash](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/da6949/32.png) [@Arash](https://www.ruby-forum.com/u/Arash)\
**Post date:** [November 5, 2007, 2:27pm UTC](https://www.ruby-forum.com/t/scaffold-in-rails-2/119215/5 "2007-11-05T14:27:25Z")

</div>

Hi Arash

IMHO, I think you would be better off looking at Active Scaffold.

CCH

> **[Rails... Rails... Rails](http://cch4rails.blogspot.com)**
>
> Chee Chong Hwa aka CCH, a Malaysian Chief Software Architect blogs on his experiences with Ruby on Rail running on Win2003 Server+Apache 2.26 environment since 2007. Flirted briefly with Ubuntu 9.04 in 2009. Since January 2017, now using RubyMine...

---

<div class="post-metadata">

**Author:** ![Arash](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/da6949/32.png) [@Arash](https://www.ruby-forum.com/u/Arash)\
**Post date:** [November 5, 2007, 5:35pm UTC](https://www.ruby-forum.com/t/scaffold-in-rails-2/119215/6 "2007-11-05T17:35:14Z")

</div>

Max W. wrote:

> William P. wrote:
> 
> > You can still get the same behavior by using the scaffold generator  
> > included with rails, only the ActionController#scaffold method has  
> > been removed. If you wanted scaffolding for the Product model, try  
> > running script/generate Product. If you run script/generate with no  
> > options, it will give you a quick help with examples. This is better  
> > anyway as it creates the controller with all of the relevant code  
> > included allowing you to see and change it.
> > 
> > Hope this helps.
> > 
> > -Bill
> 
> As far as i can tell, scaffold hasn’t been removed as such - instead its  
> functionalty has been replaced with that of the old scaffold\_resource,  
> which is used to make a RESTful scaffold. In other words, the scaffold  
> has been changed to be RESTful by default. This is going to break a lot  
> of tutorials i think. Bill, have you experienced otherwise?

I beg your pardon, Steve, dynamic scaffolding _has_ been removed but the  
non-dynamic, generated scaffolding has merely been changed to the  
restful version.
