I'm following along with the O'Reilly Rails book, but it's created for Rails 2, so I think that's where the error lies.
In app/views/entries/sign_in.html.erb:
<html>
<head><title>Hello <%=h @name %> </title> </head>
<body>
<h1> Hello <%=h @name %></h1>
<%= form_tag :action => 'sign_in' do %>
<p>Enter your name:
<%= text_field_tag 'visitor_name', @name %> </p>
<%= submit_tag 'Sign in' %>
<% end %>
</body>
</html>
And in app/controllers/entries_controller.rb:
class EntriesController < ApplicationController
def sign_in
@name = params[:visitor_name]
end
end
When I click the 'Sign In' button, it takes me to a page that says:
Routing Error
No route matches "/entries/sign_in"
I would post my routes.rb file, but it seems that it's all commented out except for this line:
get "entries/sign_in"
This file seems different than the one they're referencing in the book, so that's why I believe this to be the problem.
Thanks for your help!