From: Luis Teko Date: 2009-07-13T14:37:51+09:00 Subject: Syntax error SyntaxError in Movie#new compile error D:/instant/rails_apps/videoondemand/app/views/movie/new.html.erb:8: syntax error, unexpected ':', expecting ')' _erbout.concat(( collection_select(:movie,:genre_id,@genres:id,:name) ).to_s); _erbout.concat "

\n" ^ D:/instant/rails_apps/videoondemand/app/views/movie/new.html.erb:8: syntax error, unexpected ')', expecting tCOLON2 or '[' or '.' _erbout.concat(( collection_select(:movie,:genre_id,@genres:id,:name) ).to_s); _erbout.concat "

\n" ^ Extracted source (around line #8): 5:

: 6: <%= text_field 'movie', 'price' %>

7:

: 8: <%= collection_select(:movie,:genre_id,@genres:id,:name) %>

9:


10: <%= text_area 'movie', 'description' %>

11: <%= submit_tag "Create" %> Trace of template inclusion: /movie/new.html.erb RAILS_ROOT: D:/instant/rails_apps/videoondemand Application Trace | Framework Trace | Full Trace app/views/movie/new.html.erb:15:in `compile_template' D:/instant/ruby/bin/mongrel_rails:19 Request Parameters: None >heres my new.rhtm

Add new movie

<%= form_tag :action => 'create' %>

: <%= text_field 'movie', 'title' %>

: <%= text_field 'movie', 'price' %>

: <%= collection_select(:movie,:genre_id,@genres:id,:name) %>


<%= text_area 'movie', 'description' %>

<%= submit_tag "Create" %> <%= link_to 'Back', {:action => 'list'} %> >>movie model class Movie < ActiveRecord::Base belongs_to :genre end >>genre model class Genre < ActiveRecord::Base has_many :movies end -- Posted via http://www.ruby-forum.com/.