# Quick question - Refreshing layout

**URL:** <https://www.ruby-forum.com/t/quick-question-refreshing-layout/115466>\
**Category:** Rails\
**Created:** [September 25, 2007, 4:50pm UTC](https://www.ruby-forum.com/t/quick-question-refreshing-layout/115466 "2007-09-25T16:50:42Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![mindmage](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/f4b2a3/32.png) [@mindmage](https://www.ruby-forum.com/u/mindmage)\
**Post date:** [September 25, 2007, 4:50pm UTC](https://www.ruby-forum.com/t/quick-question-refreshing-layout/115466/1 "2007-09-25T16:50:42Z")

</div>

Hi!  
I’m trying to code a dynamic layout - menus are hidden and shown  
depending on variables stored in session.  
Is there a way to force Rails to re-render the layout?  
Because the only other option i see is making a gajillion of different  
layouts 😕

---

<div class="post-metadata">

**Author:** ![mindmage](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/f4b2a3/32.png) [@mindmage](https://www.ruby-forum.com/u/mindmage)\
**Post date:** [September 26, 2007, 5:50am UTC](https://www.ruby-forum.com/t/quick-question-refreshing-layout/115466/2 "2007-09-26T05:50:54Z")

</div>

use a render :partial or redirect\_to

On Sep 25, 10:50 am, Mind M. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)

---

<div class="post-metadata">

**Author:** ![mindmage](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/f4b2a3/32.png) [@mindmage](https://www.ruby-forum.com/u/mindmage)\
**Post date:** [September 26, 2007, 2:31pm UTC](https://www.ruby-forum.com/t/quick-question-refreshing-layout/115466/3 "2007-09-26T14:31:55Z")

</div>

Both of these, to best of my knowledge, refresh what’s inside the \<%=  
yield %\> part of the layout. I need the exact opposite - to refresh  
everything except the yield, or, if it’s not possible - a complete  
reload.
