# Namespaced controllers and helpers

**URL:** <https://discuss.rubyonrails.org/t/namespaced-controllers-and-helpers/31723>\
**Category:** rubyonrails-talk\
**Created:** [July 11, 2008, 5:20pm UTC](https://discuss.rubyonrails.org/t/namespaced-controllers-and-helpers/31723 "2008-07-11T17:20:00Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![11175](https://avatars.discourse-cdn.com/v4/letter/1/8edcca/32.png) [@11175](https://discuss.rubyonrails.org/u/11175)\
**Post date:** [July 11, 2008, 5:20pm UTC](https://discuss.rubyonrails.org/t/namespaced-controllers-and-helpers/31723/1 "2008-07-11T17:20:00Z")

</div>

Is there something different that has to be done in order to use helper modules in namespaced controllers? I have some custom helpers in app/helpers/\*\_helper.rb that work great in controllers in app/controllers but not in app/controllers/admin

In my application.rb is the line

helper :all

and the namespaced controllers are descended from ApplicationController, but when I reference one of the helper methods, I get method undefined errors. This is Rails 2.0.2.

Peace, Phillip

---

<div class="post-metadata">

**Author:** ![11175](https://avatars.discourse-cdn.com/v4/letter/1/8edcca/32.png) [@11175](https://discuss.rubyonrails.org/u/11175)\
**Post date:** [July 11, 2008, 8:10pm UTC](https://discuss.rubyonrails.org/t/namespaced-controllers-and-helpers/31723/2 "2008-07-11T20:10:06Z")

</div>

Never mind. It was a scope problem. I failed to notice that when I used these helpers in other controllers, it was in the context of a render :update block, which, I surmise, put it in the context of a view. I was trying to use the same helper method as an argument to a method that would do the render :update, so the scope was still that of the controller.

Phillip
