M
Mc Ieong
HI, I AM A NEWBIE IN RUBY, I WANT TO USE THE JAVASCRIPT, SO I ADD THIS
LINE IN THE edit.html.erb:
...
<h1>Editing order</h1>
<%= javascript_include_tag 'datagrid' %>
...
...
WHEN THIS VIEW IS RUN, IT GIVE THE FOLLOWING ERROR:
ActionController::RoutingError (No route matches
"/javascripts/datagrid.js" with
{:method=>:get}):
C:/Ruby/lib/ruby/1.8/webrick/httpserver.rb:104:in `service'
C:/Ruby/lib/ruby/1.8/webrick/httpserver.rb:65:in `run'
C:/Ruby/lib/ruby/1.8/webrick/server.rb:173:in `start_thread'
C:/Ruby/lib/ruby/1.8/webrick/server.rb:162:in `start'
C:/Ruby/lib/ruby/1.8/webrick/server.rb:162:in `start_thread'
C:/Ruby/lib/ruby/1.8/webrick/server.rb:95:in `start'
C:/Ruby/lib/ruby/1.8/webrick/server.rb:92:in `each'
C:/Ruby/lib/ruby/1.8/webrick/server.rb:92:in `start'
C:/Ruby/lib/ruby/1.8/webrick/server.rb:23:in `start'
C:/Ruby/lib/ruby/1.8/webrick/server.rb:82:in `start'
Rendering rescues/layout (not_found)
MY routes.rb IS JUST LIKE THIS:
map.resources rders
map.connect ':controller/:action/:id'
map.connect ':controller/:action/:id.:format'
CAN ANYBODY TELL ME WHAT WAS WRONG? HELP!
LINE IN THE edit.html.erb:
...
<h1>Editing order</h1>
<%= javascript_include_tag 'datagrid' %>
...
...
WHEN THIS VIEW IS RUN, IT GIVE THE FOLLOWING ERROR:
ActionController::RoutingError (No route matches
"/javascripts/datagrid.js" with
{:method=>:get}):
C:/Ruby/lib/ruby/1.8/webrick/httpserver.rb:104:in `service'
C:/Ruby/lib/ruby/1.8/webrick/httpserver.rb:65:in `run'
C:/Ruby/lib/ruby/1.8/webrick/server.rb:173:in `start_thread'
C:/Ruby/lib/ruby/1.8/webrick/server.rb:162:in `start'
C:/Ruby/lib/ruby/1.8/webrick/server.rb:162:in `start_thread'
C:/Ruby/lib/ruby/1.8/webrick/server.rb:95:in `start'
C:/Ruby/lib/ruby/1.8/webrick/server.rb:92:in `each'
C:/Ruby/lib/ruby/1.8/webrick/server.rb:92:in `start'
C:/Ruby/lib/ruby/1.8/webrick/server.rb:23:in `start'
C:/Ruby/lib/ruby/1.8/webrick/server.rb:82:in `start'
Rendering rescues/layout (not_found)
MY routes.rb IS JUST LIKE THIS:
map.resources rders
map.connect ':controller/:action/:id'
map.connect ':controller/:action/:id.:format'
CAN ANYBODY TELL ME WHAT WAS WRONG? HELP!