Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
如何配置mmenu以在 (m)menu 中指示当前页面?每个页面上都包含一些内容吗?
Mmenu 将根据其类设置当前页面的样式。例如,如果您使用 Wordpress,则当前页面被赋予“当前菜单项”类。当您加载 mmenu 时,您需要告诉它您为当前页面提供的类(默认为“已选择”):
jQuery("#menu-top").mmenu({ //options }, { //configuration classNames: { selected: "current-menu-item" } });