# Resource routes for acts\_as\_tree - help

**URL:** <https://www.ruby-forum.com/t/resource-routes-for-acts-as-tree-help/121988>\
**Category:** Rails\
**Created:** [December 3, 2007, 5:35pm UTC](https://www.ruby-forum.com/t/resource-routes-for-acts-as-tree-help/121988 "2007-12-03T17:35:27Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![goodieboy](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/ecc23a/32.png) [@goodieboy](https://www.ruby-forum.com/u/goodieboy)\
**Post date:** [December 3, 2007, 5:35pm UTC](https://www.ruby-forum.com/t/resource-routes-for-acts-as-tree-help/121988/1 "2007-12-03T17:35:27Z")

</div>

Hi,

I’d like to be able to define the children of a node as a resource  
like so:

/content\_nodes/1/children  
/content\_nodes/1/children.js  
/content\_nodes/1/children.xml

etc., but can’t figure this out. Usually, the nested route is a model  
but in this case children is something setup by acts\_as\_tree. Is this  
at all possible?

Thank you

---

<div class="post-metadata">

**Author:** ![goodieboy](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/ecc23a/32.png) [@goodieboy](https://www.ruby-forum.com/u/goodieboy)\
**Post date:** [December 3, 2007, 6:09pm UTC](https://www.ruby-forum.com/t/resource-routes-for-acts-as-tree-help/121988/2 "2007-12-03T18:09:00Z")

</div>

Yeah!

map.resources :content\_nodes do |content\_nodes|  
content\_nodes.resources :children, :controller=\>‘content\_nodes’  
end
