# Yield external file

**URL:** <https://www.ruby-forum.com/t/yield-external-file/125090>\
**Category:** Rails\
**Created:** [January 5, 2008, 7:57am UTC](https://www.ruby-forum.com/t/yield-external-file/125090 "2008-01-05T07:57:41Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![musty](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/77aa72/32.png) [@musty](https://www.ruby-forum.com/u/musty)\
**Post date:** [January 5, 2008, 7:57am UTC](https://www.ruby-forum.com/t/yield-external-file/125090/1 "2008-01-05T07:57:41Z")

</div>

Hello All  
I currently have a menu on my page which when an option is selected will  
display the associated rhtml file from one of the views/ directories,  
nothing fancy works great. I’m trying to extend the menu options to  
include some older php files that i have not migrated to RoR yet. I  
guess just putting the files in a new views directory and referencing it  
as i do the others would work but i can’t move them.  
If i do the following it starts a new page, I need it to be displayed as  
the content of my current page.  
\<%= link\_to “Test”, “[http://www.helpme.com/](http://www.helpme.com/)” -%\>  
Any way to treat a non-views/ directory file like a view/ directory  
file?

Hope that makes sense, any help appreciated, thanks…Bill

---

<div class="post-metadata">

**Author:** ![musty](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/77aa72/32.png) [@musty](https://www.ruby-forum.com/u/musty)\
**Post date:** [January 11, 2008, 6:22am UTC](https://www.ruby-forum.com/t/yield-external-file/125090/2 "2008-01-11T06:22:12Z")

</div>

Bill McG wrote:

> Hello All  
> I currently have a menu on my page which when an option is selected will  
> display the associated rhtml file from one of the views/ directories,  
> nothing fancy works great. I’m trying to extend the menu options to  
> include some older php files that i have not migrated to RoR yet. I  
> guess just putting the files in a new views directory and referencing it  
> as i do the others would work but i can’t move them.  
> If i do the following it starts a new page, I need it to be displayed as  
> the content of my current page.  
> \<%= link\_to “Test”, “[http://www.helpme.com/](http://www.helpme.com/)” -%\>  
> Any way to treat a non-views/ directory file like a view/ directory  
> file?
> 
> Hope that makes sense, any help appreciated, thanks…Bill

Can anyone help with this. Trying to get an rhtml file from a non-rails  
directory to show up where yield would normally display a rhtml file  
from a apps\views directory. Thanks
