SitePoint Sponsor |
|
User Tag List
Results 1 to 4 of 4
Thread: Rails template not loading up
-
Sep 16, 2006, 16:43 #1
- Join Date
- Nov 2003
- Location
- New Jersey
- Posts
- 195
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Rails template not loading up
Hello,
I literally just started learing Ruby on Rails today so I am very new. To help I picked up the Agile Web Development book too and I have hit a little snag about 30 pages into it.
I installed Ruby and Rails just like the book said. I then stopped apache2 (which is my default server)
I created a new rails directory like so...
Code:$> rails demo
Code:demo> script/server
I created a controller called Say
Code:demo> script/generate controller Say
I then went inside the controller and defined a method called hello()
Code:class SayController < ApplicationController def hello end end
Also, I stopped apache2 because I figured there may be some conflict having 2 webservers running at the same time. Should I stop it or is it OK to run apache and WEBrick at the same time?
Thanks in advance.-- Joe C --
"Do or do not. There is no try..."
- Yoda
-
Sep 16, 2006, 22:15 #2
- Join Date
- Jan 2006
- Posts
- 268
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
can we see your view file?
-
Sep 16, 2006, 23:16 #3
- Join Date
- Aug 2005
- Posts
- 986
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
The rhtml file should be in views/say/hello.rhtml because it's in the say controller.
-
Sep 17, 2006, 16:55 #4
- Join Date
- Nov 2003
- Location
- New Jersey
- Posts
- 195
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Thanks for the relplies guys,
I actually figured out the problem. Everything was in the correct place, it was a problem with my install. I am running Ubuntu and it looks like gems didn't actually install all the packages that I needed. I ended up doing this:
Code:> sudo apt-get install rails irb ri1.8 ruby1.8-dev
-- Joe C --
"Do or do not. There is no try..."
- Yoda
Bookmarks