# Adding To View Path - Not Picking Up Templates?

**URL:** <https://www.ruby-forum.com/t/adding-to-view-path-not-picking-up-templates/122594>\
**Category:** Rails\
**Created:** [December 9, 2007, 11:35pm UTC](https://www.ruby-forum.com/t/adding-to-view-path-not-picking-up-templates/122594 "2007-12-09T23:35:37Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![hunter\_h](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/h/bc79bd/32.png) [@hunter\_h](https://www.ruby-forum.com/u/hunter_h)\
**Post date:** [December 9, 2007, 11:35pm UTC](https://www.ruby-forum.com/t/adding-to-view-path-not-picking-up-templates/122594/1 "2007-12-09T23:35:37Z")

</div>

So, I’m adding a secondary template location to ActionController’s  
view\_paths so that I can dynamically choose the render path (basic  
‘theme’ support).

I can see that ActionController::Base.view\_paths contains my new path  
before the default path but I can’t ever seem to render the template  
in my path. I have a template in both the default and new locations  
and the default is always rendered. If I remove it, I get an  
assert\_template\_exists error.

I must be missing something about how Rails 2 chooses its templates.  
Ideally it would use the template in the new location if it exists and  
if not, fail over to the default location.

Any pointers?

Thx.
