jsTree: how to retrieve 'metadata'?
I tried this example, but there is still a problem - I could 开发者_运维知识库not get 'metadata' value. Could somebody show one more example?
That example is working fine for me with version 1.0-rc3
Here's another:
{
'attr': {'id': 'example1'},
'data': {
'attr': {
'href': '#'
},
'title': 'Example'
},
'metadata': {
'hello': 'world'
}
}
And to retrieve the metadata:
$(node).data('hello'); // world
精彩评论