RailsCasts Pro episodes are now free!
Learn more or hide this
GitHub User: SeriouslyAwesome
Site: http://www.seriouslyawesome.com
Yes, you could do something like this:
<ul class="items"> <li>Root Item 1</li> <li>Root Item 2</li> <li> Root Item 3 With Children <ul style="display:none;"> <li>Child Item 1</li> <li>Child Item 2</li> </ul> </li> </ul>
And then open the submenu with, let's say jQuery:
$(function(){ $("ul.items li").click(function(){ $(this).children('ul').toggle(); }); });
Yes, you could do something like this:
And then open the submenu with, let's say jQuery: