title: Preserve the opened/closed state of my sub-menus when navigate to another page
body: <p>I have an asp.net mvc4 solution.</p>
  
  <p>I have a menu on the left side. By default this menu is closed.</p>
  
  <p><img src="https://i.stack.imgur.com/oNaiz.png" alt="enter image description here"></p>
  
  <p>If I click on an item, a sub-menu is showed.</p>
  
  <p><img src="https://i.stack.imgur.com/I9BUi.png" alt="enter image description here"></p>
  
  <p><strong>The problem</strong> is when I navigate to another page, the opened/closed state of sub-menus are forgotten. The new page is showed and all sub-menus are still closed. I would like to preserve the opend/closed state of these sub-menus. How can I proceed?</p>
  
  <p>Here is a portion of my left side menu:</p>
  
  <pre><code>&lt;div class="page-sidebar"&gt;
      &lt;ul&gt;
          &lt;li class="dropdown" data-role="dropdown"&gt;
              &lt;a&gt;&lt;i class="icon-flip-2"&gt;&lt;/i&gt; Transports&lt;/a&gt;
              &lt;ul class="sub-menu light sidebar-dropdown-menu"&gt;
                  &lt;li&gt;@Html.ActionLink("En cours", "SearchTransportsAA", "Transp")&lt;/a&gt;&lt;/li&gt;
                  &lt;li&gt;@Html.ActionLink("Passés", "SearchTransportsBB", "Transp")&lt;/a&gt;&lt;/li&gt;
                  &lt;li&gt;@Html.ActionLink("Factures", "SearchTransportsCC", "Transp")&lt;/a&gt;&lt;/li&gt;
              &lt;/ul&gt;
          &lt;/li&gt;
          &lt;li class="dropdown" data-role="dropdown"&gt;
              &lt;a&gt;&lt;i class="icon-drawer-2"&gt;&lt;/i&gt; Autorisations&lt;/a&gt;
              &lt;ul class="sub-menu light sidebar-dropdown-menu open"&gt;
                  &lt;li&gt;@Html.ActionLink("Valides", "SearchAutorisAA", "Transp")&lt;/a&gt;&lt;/li&gt;
                  &lt;li&gt;@Html.ActionLink("Périmés", "SearchAutorisBB", "Transp")&lt;/a&gt;&lt;/li&gt;
                  &lt;li&gt;@Html.ActionLink("Recherche", "SearchAutorisCC", "Transp")&lt;/a&gt;&lt;/li&gt;
              &lt;/ul&gt;
          &lt;/li&gt;
          ...
          ...
  </code></pre>
  
  <p>As you can see above, when <strong>'open'</strong> is added to the class, the menu is marked to be open.</p>