I am trying to extract the root path to the current item in the MultiLevelPushMenu plugin.
https://github.com/adgsm/multi-level-push-menu
Ownerprovided Method to extract the root level of the path to the document
/**
* Find path to root of selected menu level object
* Provides chain collection of menu level objects (root menu level object to given menu level object), or false in case of error
*/
$('#menu').multilevelpushmenu('pathtoroot', $menuLevelObject);
I tried using the same as for recommendations, but I get HTMLLiobject, but I can not dig into the path.
I need a path to the string format from this collection, any help?
here is my code ..
$(document).ready(function(){
$( '#menu' ).multilevelpushmenu({
containersToPush: [$( '#pushobj' )],
menuWidth: '25%',
menuHeight: '100%',
onItemClick: function() {
var event = arguments[0],
element)
$menuLevelHolder = arguments[1],
element)
$item = arguments[2],
options = arguments[3];
var path = $('#menu').multilevelpushmenu('pathtoroot', $item);
alert(path);
}
});
});
that's what i get
source
share