Undefined method 'act_as_tree'

I have 2 models: topic model and post:

class Topic < ActiveRecord::Base
has_many :posts
end

class Post < ActiveRecord::Base
acts_as_tree :order=>“body”
belongs_to :topic
end

and I have a view for creating new topic (and new post):

Add a new Topic

<% form_for :topic, @topic, :url => { :action => “create” } do |f| %>
Title: <%= f.text_field :title %>

<% fields_for :posts do |post| %>
Body:<%= post.text_field :body %>

<% end %>

<%= submit_tag ‘Post Topic’, :class => “submit” %>
<% end %>

I get the undefined method ‘act_as_tree’ error in the
TopicsController: (in the create method)
@post = Post.new(params[:post])

any ideas?

On 24 Nov 2007, at 23:41, oren wrote:

class Post < ActiveRecord::Base
acts_as_tree :order=>“body”
belongs_to :topic
end

I get the undefined method ‘act_as_tree’ error in the

What version of rails are you running? In 2.0 acts_as_tree (along with
a bunch of stuff) has been moved into separate plugins.

Fred

edge…
I guess I need to google for this plug-in.

thanks!

On Nov 24, 4:04 pm, Frederick C. [email protected]