There seems to have been a lot of confusion in the discussion in the
answers to your question (mention of ./app/model where there is none, etc.).
I have one simple question for you: did you create a view? The method is
invoked, but must have a corresponding view (rhtml). This is covered in the
tutorial that you mention, I believe.
From: Roberto Mason <baubba@rmasonfamily.info>> To: Ruby On Rails <rails@lists.rubyonrails.org>
> Date: Mon, 27 Mar 2006 22:31:41 -0500
> Subject: [Rails] blank page output
> Hello, I''m new to Ruby and RubyOnRails. I''m running
Fedora 4 which comes
> with Ruby 1.84-1. I installed rubyonrails, and I''m doing the a
sample
> program found on
> http://www.onlamp.com/pub/a/onlamp/2005/01/20/rails.html?page=2
> I ran ruby script/generate controller MyTest. I edited the file
> my_test_controller.rb. Here''s the code I entered
>
> class MyTestController < ApplicationController
> def index
> render_text "Hello World, my first line of Ruby"
> end
> end
>
> I save the file. I then ran the browser with the following url
>
> http://127.0.0.1:3000/My_Test/
>
> I get a blank page, no output.
>
> if I do
>
> http://127.0.0.1:3000/garbage/
>
> I still get a blank page instead of a NOT FOUND message.
>
> I know I''m doing something wrong, but I can''t figure out
what.
>
> If anyone out there has an idea what, Thanks :)
>
>
>
>
>
> --
> This message has been scanned for viruses and
> dangerous content by MailScanner, and is
> believed to be clean.
>
>
>
>
>
> ---------- Forwarded message ----------
> From: Zed Shaw <zedshaw@zedshaw.com>
> To: "rails@lists.rubyonrails.org"
<rails@lists.rubyonrails.org>
> Date: Mon, 27 Mar 2006 22:35:14 -0500
> Subject: Re: [Rails] [ANN] Mongrel Web Server 0.3.12 -- Pre-Release
> Jonathan,
>
> It does have support for extending mime types. Take a look at the -h for
> start:
>
> Usage: mongrel_rails [options]
> -e, --environment ENV Rails environment to run as
> -d, --daemonize Whether to run in the background or
> not
> -p, --port PORT Which port to bind to
> -a, --address ADDR Address to bind to
> -l, --log FILE Where to write log messages
> -P, --pid FILE Where to write the PID
> -n, --num-procs INT Number of processor threads to use
> -t, --timeout SECONDS Timeout all requests after SECONDS
> time
> -m, --mime PATH A YAML file that lists additional
> MIME
> types
> -c, --chdir PATH Change to dir before starting (will
> be
> expanded)
> -r, --root PATH Set the document root (default
> ''public'')
> -B, --debug Enable debugging mode
> -C, --config PATH Use a config file
> -h, --help Show this message
> --version Show version
>
> You pass it -m and a YAML file with the mapping of any mime types you
> want.
> Mongrel has a very small default set since there actually isn''t
much of a
> "standard" on the types and postfix mapping doesn''t help
much for things
> like Rails.
>
> Here''s an example mime file:
>
> ---
> .jpeg: image/jpeg
> .png: image/test
>
> The --- is important.
>
> Zed A. Shaw
> http://www.zedshaw.com/
> http://mongrel.rubyforge.org/
>
>
> On 3/27/06 5:23 PM, "Jonathan Weiss" <jw@innerewut.de>
wrote:
>
> > Hi Zed,
> >
> >>
> >> Try out the release and let me know if I missed anything. It
should
> work
> >> with Rails 1.1RC1 but I haven''t tested extensively.
> >
> > At least with 0.3.11 there seems to be no support for mime-types. The
> > server does not set default mime-types for docs, pdfs & co if I
download
> > a file directly from the filesystem.
> >
> > IMHO this is needed if you want to use Mongrel as an easy to setup
> > Windows deployment.
> >
> > Greets,
> > Jonathan
> >
>
>
>
>
>
> ---------- Forwarded message ----------
> From: Zed Shaw <zedshaw@zedshaw.com>
> To: "mongrel-users@rubyforge.org"
<mongrel-users@rubyforge.org>, "
> rails@lists.rubyonrails.org" <rails@lists.rubyonrails.org>,
"
> ruby-talk@ruby-lang.org" <ruby-talk@ruby-lang.org>
> Date: Mon, 27 Mar 2006 22:47:20 -0500
> Subject: [Rails] Mongrel Web Server 0.3.12 -- Updated, Getting Closer
> Everyone tracking the Mongrel 0.3.12 pre-release should dump their current
> install and re-install:
>
> $ gem uninstall mongrel
> $ gem uninstall gem_plugin
> $ gem install mongrel --source=http://mongrel.rubyforge.org/releases/
>
> This release fixes a problem with specifying a directory to change to, and
> fixes the incredibly broken DirHandler code from last night.
>
> The big change people will probably notice with static file serving is
> that
> IE will seem like it''s flying. This is because the DirHandler
properly
> implements the HEAD and GET requests differently for files, and denies
> anything else. IE is notorious for spamming web servers with tons of HEAD
> requests so this makes it speed up a bit.
>
> I''ll be tweaking the DirHandler a bit more to include caching
directives
> for
> the files it serves.
>
> Enjoy and let me know what people encounter.
>
> Zed A. Shaw
> http://www.zedshaw.com/
> http://mongrel.rubyforge.org/releases/
>
>
>
>
>
> ---------- Forwarded message ----------
> From: Craig White <craigwhite@azapple.com>
> To: rails@lists.rubyonrails.org
> Date: Mon, 27 Mar 2006 20:55:15 -0700
> Subject: Re: [Rails] blank page output
> On Mon, 2006-03-27 at 22:31 -0500, Roberto Mason wrote:
> > Hello, I''m new to Ruby and RubyOnRails. I''m running
Fedora 4 which comes
> > with Ruby 1.84-1. I installed rubyonrails, and I''m doing the
a sample
> > program found on
> > http://www.onlamp.com/pub/a/onlamp/2005/01/20/rails.html?page=2
> > I ran ruby script/generate controller MyTest. I edited the file
> > my_test_controller.rb. Here''s the code I entered
> >
> > class MyTestController < ApplicationController
> > def index
> > render_text "Hello World, my first line of
Ruby"
> > end
> > end
> >
> > I save the file. I then ran the browser with the following url
> >
> > http://127.0.0.1:3000/My_Test/
> >
> > I get a blank page, no output.
> >
> > if I do
> >
> > http://127.0.0.1:3000/garbage/
> >
> > I still get a blank page instead of a NOT FOUND message.
> >
> > I know I''m doing something wrong, but I can''t figure
out what.
> >
> > If anyone out there has an idea what, Thanks :)
> ----
> try lower case...
>
> http://127.0.0.1:3000/my_test
> or (I find this easier)
> http://localhost:3000/my_test
> or (I find this even easier)
> localhost/my_test
>
> Windows seems to ignore case sensitivities...
>
> Windows sees "My_Test" and "my_test" as the same name,
UNIX/Linux does
> not.
>
> Craig
>
>
>
>
>
> ---------- Forwarded message ----------
> From: Roberto Mason <baubba@rmasonfamily.info>
> To: rails@lists.rubyonrails.org
> Date: Mon, 27 Mar 2006 22:58:56 -0500
> Subject: Re: [Rails] blank page output
> I''m running this on my Fedora 4. I''ve tried lowercase,
but same result
>
>
> On Mon, 2006-03-27 at 20:55 -0700, Craig White wrote:
> > On Mon, 2006-03-27 at 22:31 -0500, Roberto Mason wrote:
> > > Hello, I''m new to Ruby and RubyOnRails. I''m
running Fedora 4 which
> comes
> > > with Ruby 1.84-1. I installed rubyonrails, and I''m doing
the a sample
> > > program found on
> > > http://www.onlamp.com/pub/a/onlamp/2005/01/20/rails.html?page=2
> > > I ran ruby script/generate controller MyTest. I edited the file
> > > my_test_controller.rb. Here''s the code I entered
> > >
> > > class MyTestController < ApplicationController
> > > def index
> > > render_text "Hello World, my first line of
Ruby"
> > > end
> > > end
> > >
> > > I save the file. I then ran the browser with the following url
> > >
> > > http://127.0.0.1:3000/My_Test/
> > >
> > > I get a blank page, no output.
> > >
> > > if I do
> > >
> > > http://127.0.0.1:3000/garbage/
> > >
> > > I still get a blank page instead of a NOT FOUND message.
> > >
> > > I know I''m doing something wrong, but I can''t
figure out what.
> > >
> > > If anyone out there has an idea what, Thanks :)
> > ----
> > try lower case...
> >
> > http://127.0.0.1:3000/my_test
> > or (I find this easier)
> > http://localhost:3000/my_test
> > or (I find this even easier)
> > localhost/my_test
> >
> > Windows seems to ignore case sensitivities...
> >
> > Windows sees "My_Test" and "my_test" as the same
name, UNIX/Linux does
> > not.
> >
> > Craig
> >
> > _______________________________________________
> > Rails mailing list
> > Rails@lists.rubyonrails.org
> > http://lists.rubyonrails.org/mailman/listinfo/rails
> >
>
>
> --
> This message has been scanned for viruses and
> dangerous content by MailScanner, and is
> believed to be clean.
>
>
>
>
>
> ---------- Forwarded message ----------
> From: Craig White <craigwhite@azapple.com>
> To: rails@lists.rubyonrails.org
> Date: Mon, 27 Mar 2006 21:03:21 -0700
> Subject: Re: [Rails] blank page output
> what is output of...
>
> cd cookbook # get into the right directory on the command line
>
> cat app/models/my_test_controller.rb
>
> tail log/development.log
>
> Craig
>
> On Mon, 2006-03-27 at 22:58 -0500, Roberto Mason wrote:
> > I''m running this on my Fedora 4. I''ve tried
lowercase, but same result
> >
> >
> > On Mon, 2006-03-27 at 20:55 -0700, Craig White wrote:
> > > On Mon, 2006-03-27 at 22:31 -0500, Roberto Mason wrote:
> > > > Hello, I''m new to Ruby and RubyOnRails.
I''m running Fedora 4 which
> comes
> > > > with Ruby 1.84-1. I installed rubyonrails, and I''m
doing the a
> sample
> > > > program found on
> > > >
http://www.onlamp.com/pub/a/onlamp/2005/01/20/rails.html?page=2
> > > > I ran ruby script/generate controller MyTest. I edited the
file
> > > > my_test_controller.rb. Here''s the code I entered
> > > >
> > > > class MyTestController < ApplicationController
> > > > def index
> > > > render_text "Hello World, my first line of
Ruby"
> > > > end
> > > > end
> > > >
> > > > I save the file. I then ran the browser with the following
url
> > > >
> > > > http://127.0.0.1:3000/My_Test/
> > > >
> > > > I get a blank page, no output.
> > > >
> > > > if I do
> > > >
> > > > http://127.0.0.1:3000/garbage/
> > > >
> > > > I still get a blank page instead of a NOT FOUND message.
> > > >
> > > > I know I''m doing something wrong, but I
can''t figure out what.
> > > >
> > > > If anyone out there has an idea what, Thanks :)
> > > ----
> > > try lower case...
> > >
> > > http://127.0.0.1:3000/my_test
> > > or (I find this easier)
> > > http://localhost:3000/my_test
> > > or (I find this even easier)
> > > localhost/my_test
> > >
> > > Windows seems to ignore case sensitivities...
> > >
> > > Windows sees "My_Test" and "my_test" as the
same name, UNIX/Linux does
> > > not.
> > >
> > > Craig
> > >
> > > _______________________________________________
> > > Rails mailing list
> > > Rails@lists.rubyonrails.org
> > > http://lists.rubyonrails.org/mailman/listinfo/rails
> > >
> >
> >
>
>
>
>
>
> ---------- Forwarded message ----------
> From: Miles Monroe <aaronbecker17@gmail.com>
> To: rails@lists.rubyonrails.org
> Date: Tue, 28 Mar 2006 06:12:39 +0200
> Subject: [Rails] Newbie question: Dynamic view creation from
> obj.to_html_form
>
> Hi. I would like to be able to generate a form dynamically from an
> object''s to_html_form method, submit it, and then place marshalled
> object into a database row.
>
> Since I do not know exactly all the input fields in advance, I figure
> this would allow me to dynamically create the input form, stuff the user
> input into object, marshal the object into the database, and display it
> later dynamically for the user to edit again.
>
> I actually need to use the composite design model and so I will perhaps
> have nested objects with form information. I should be able to marshal
> and unmarshal these objects without difficulty.
>
> How do I do this in Rails? This would be pretty cool because I could
> all sorts of objects and their associated forms in the same table. I
> could have a column for class name to iterate through all the same
> objects that I am interested in.
>
> Thanks.
>
> --
> Posted via http://www.ruby-forum.com/.
>
>
>
> _______________________________________________
> Rails mailing list
> Rails@lists.rubyonrails.org
> http://lists.rubyonrails.org/mailman/listinfo/rails
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
http://wrath.rubyonrails.org/pipermail/rails/attachments/20060328/82eb47fc/attachment-0001.html