我在codeigniter站点中使用zurb Foundation 4,在桌面版本中,我将登录右上角作为下拉菜单,但是当鼠标从下拉菜单的内容移开时,它会关闭,我想知道是否除非用户单击页面上的其他位置,否则它可以保持打开状态。
请参阅我在基金会网站文档中解释的示例:http: //foundation.zurb.com/docs/components/top-bar.html
我只需要编辑该示例,以便在鼠标移开时下拉菜单不会关闭。
我正在使用下面的基本代码:
<nav class="top-bar">
<ul class="title-area">
<!-- Title Area -->
<li class="name">
<h1><a href="test">M450N</a></h1>
</li>
<!-- Remove the class "menu-icon" to get rid of menu icon. Take out "Menu" to just have icon alone -->
<li class="toggle-topbar menu-icon"><a href="#"><span></span></a></li>
</ul>
<section class="top-bar-section">
<!-- Left Nav Section -->
<ul class="left">
<li class="divider"></li>
<li class="active"><a href="about">About</a></li>
<li class="divider"></li>
<li><a href="index">Events</a></li>
<li class="divider"></li>
<li><a href="#">Music</a></li>
</ul>
<!-- Right Nav Section THIS IS THE PROBLEM SECTION -->
<ul class="right">
<li class="divider"></li>
<li class="has-dropdown"><a href="#">Login</a>
<ul class="dropdown">
<li class="has-dropdown">
<div class="panel">
<input type = "text" value = "Username"/><br />
<input type = "text" value = "Password"/><br />
<input type = "Submit" value = "Login"/></div>
</li>
</ul>
</section>
</nav>
基础 CSS: http: //pastebin.com/iRpqtY2G
主要CSS: http: //pastebin.com/fBExPY1j