Where are my .rhtml pages?

Hi I have created a rails app with my own ERD based on the rolling with
rails tut.
I have c:\ruby and c:\rails\myapp. According to the tut I should have
all my generated .rhtml files under …myapp\views\abc.rhtml etc, but I
have none whatsoever.

I have years of dev experience, but am sad to say flumoxed at this
point.

any help will be appreciated.

On 11/22/06, ed [email protected] wrote:

any help will be appreciated.

hate to ask the obvious (to me at least), but have you generated the
views yet?

more info would be nice. what steps have you done so far?

Chris M.
Web D.
Open Source & Web Standards Advocate
http://www.chriscodes.com/

Chris M. wrote:

On 11/22/06, ed [email protected] wrote:

any help will be appreciated.

hate to ask the obvious (to me at least), but have you generated the
views yet?

more info would be nice. what steps have you done so far?

Chris M.
Web D.
Open Source & Web Standards Advocate
http://www.chriscodes.com/

Hi Chris, I generated the models and controllers and then manually added
the scaffold code to the relevant controller. The app works fine now
(well once I got used to the plurals way of rails :slight_smile: ) and all the
relevant views folders are there, just not the .rhtml pages.

Excellent thanks I’ll give that a bash.

ed wrote:

Chris M. wrote:

On 11/22/06, ed [email protected] wrote:

any help will be appreciated.

hate to ask the obvious (to me at least), but have you generated the
views yet?

more info would be nice. what steps have you done so far?

Chris M.
Web D.
Open Source & Web Standards Advocate
http://www.chriscodes.com/

Hi Chris, I generated the models and controllers and then manually added
the scaffold code to the relevant controller. The app works fine now
(well once I got used to the plurals way of rails :slight_smile: ) and all the
relevant views folders are there, just not the .rhtml pages.

You need to create them yourself, or actually generate the scaffold.

if in your controller you have:

class Foo < ApplicationController
def index
@foos = Foo.find(:all)
end
end

Then you need to create a view in:

your_app/app/views/foo/index.rhtml

Or alternatively, you can run the scaffold generator which writes out
the controller code and rhtml templates so you can start messing with
them.

ruby script/generate scaffold MyModel

On 11/22/06, Alex W. [email protected] wrote:

more info would be nice. what steps have you done so far?
(well once I got used to the plurals way of rails :slight_smile: ) and all the
end

yep. see this for more info
http://wiki.rubyonrails.org/rails/pages/ScaffoldGenerator

Chris M.
Web D.
Open Source & Web Standards Advocate
http://www.chriscodes.com/

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs