Demo
Example
JS Array 형식으로도 가능하다.
<html> <head> <link rel="stylesheet" href="//netdna.bootstrapcdn.com/font-awesome/4.0.1/css/font-awesome.min.css"> <link href='http://fonts.googleapis.com/css?family=Open+Sans+Condensed:300,300italic,700&subset=latin,cyrillic-ext,latin-ext,cyrillic' rel='stylesheet' type='text/css'> <link rel="stylesheet" href="multilevelpushmenu.css" /> <script src="//ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script> <script src="//oss.maxcdn.com/libs/modernizr/2.6.2/modernizr.min.js"></script> <script src="jquery.multilevelpushmenu.min.js></script> <script> $(document).ready(function(){ $('#menu').multilevelpushmenu(); }); </script> </head> <body> <div id="menu"> <nav> <h2><i class="fa fa-reorder"></i>All Categories</h2> <ul> <li> <a href="#"><i class="fa fa-laptop"></i>Devices</a> <h2><i class="fa fa-laptop"></i>Devices</h2> <ul> <li> <a href="#"><i class="fa fa-phone"></i>Mobile Phones</a> <h2><i class="fa fa-phone"></i>Mobile Phones</h2> <ul> <li> <a href="#">Super Smart Phone</a> </li> <li> <a href="#">Thin Magic Mobile</a> </li> <li> <a href="#">Performance Crusher</a> </li> <li> <a href="#">Futuristic Experience</a> </li> </ul> </li> <li> <a href="#"><i class="fa fa-desktop"></i>Televisions</a> <h2><i class="fa fa-desktop"></i>Televisions</h2> <ul> <li> <a href="#">Flat Super Screen</a> </li> <li> <a href="#">Gigantic LED</a> </li> <li> <a href="#">Power Eater</a> </li> <li> <a href="#">3D Experience</a> </li> <li> <a href="#">Classic Comfort</a> </li> </ul> </li> <li> <a href="#"><i class="fa fa-camera-retro"></i>Cameras</a> <h2><i class="fa fa-camera-retro"></i>Cameras</h2> <ul> <li> <a href="#">Smart Shot</a> </li> <li> <a href="#">Power Shooter</a> </li> <li> <a href="#">Easy Photo Maker</a> </li> <li> <a href="#">Super Pixel</a> </li> </ul> </li> </ul> </li> <li> <a href="#"><i class="fa fa-book"></i>Magazines</a> <h2><i class="fa fa-book"></i>Magazines</h2> <ul> <li> <a href="#">National Geographics</a> </li> <li> <a href="#">The Spectator</a> </li> <li> <a href="#">Rambler</a> </li> <li> <a href="#">Physics World</a> </li> <li> <a href="#">The New Scientist</a> </li> </ul> </li> <li> <a href="#"><i class="fa fa-shopping-cart"></i>Store</a> <h2><i class="fa fa-shopping-cart"></i>Store</h2> <ul> <li> <a href="#"><i class="fa fa-tags"></i>Clothes</a> <h2><i class="fa fa-tags"></i>Clothes</h2> <ul> <li> <a href="#"><i class="fa fa-female"></i>Women's Clothing</a> <h2><i class="fa fa-female"></i>Women's Clothing</h2> <ul> <li> <a href="#">Tops</a> </li> <li> <a href="#">Dresses</a> </li> <li> <a href="#">Trousers</a> </li> <li> <a href="#">Shoes</a> </li> <li> <a href="#">Sale</a> </li> </ul> </li> <li> <a href="#"><i class="fa fa-male"></i>Men's Clothing</a> <h2><i class="fa fa-male"></i>Men's Clothing</h2> <ul> <li> <a href="#">Shirts</a> </li> <li> <a href="#">Trousers</a> </li> <li> <a href="#">Shoes</a> </li> <li> <a href="#">Sale</a> </li> </ul> </li> </ul> </li> <li> <a href="#">Jewelry</a> </li> <li> <a href="#">Music</a> </li> <li> <a href="#">Grocery</a> </li> </ul> </li> <li> <a href="#">Collections</a> </li> <li> <a href="#">Credits</a> </li> </ul> </nav> </div> </body> </html>
반응형
'lang > jquery' 카테고리의 다른 글
jQiery jointer - 요소간 연결선을 그려준다. (0) | 2018.08.20 |
---|---|
구글 차트 API 로 원형(pi)차트 그리기 (0) | 2018.07.17 |
$.deferred 비동기 호출 서비스 (0) | 2014.10.13 |
jquery mobile 페이지 전환 깜박거림 (0) | 2013.11.26 |
jQuery가 지원하는 고급 위치 기반 셀렉터 (0) | 2010.07.30 |