My project was working when I add new field category
It is showing the error in create form and edit form
i am sending u controller file as attechment
this is my model(category.rb) dor category file
class Category < ActiveRecord::Base
has_many :classifieds
end
and this is edit.rhtml
<h1>Editing Classified: <%= @classified.title -%></h1>
<%= form_tag :action => 'update', :id => @classified %>
<p><label for="classified_title">Title</label><br/>
<%= text_field 'classified', 'title' %></p>
<p><label for="classified_price">Price</label><br/>
<%= text_field 'classified', 'price' %></p>
<p><label for="classified_location">Location</label><br/>
<%= text_field 'classified', 'location' %></p>
<p><label for="classified_description">Description</label><br/>
<%= text_area 'classified', 'description' %></p>
<p><label for="classified_category">Category</label><br />
<%= collection_select(:classified, :category_id, @categories,
:id, :name) %></p>
<p><label for="classified_email">Email</label><br/>
<%= text_field 'classified', 'email' %></p>
<%= submit_tag "Save changes" %>
<%= form_tag %>
<%= link_to 'Back', {:action => 'list' } %>
on 09.05.2008 12:11