How can I get the id of the selected node in a jsTree?
function createNewNode() {
alert(\'test\');
var tree = $.tree.reference(\"#basic_html\");
select
to get all selected ids use the below code
var selectedData = [];
var selectedIndexes;
selectedIndexes = $("#jstree").jstree("get_selected", true);
jQuery.each(selectedIndexes, function (index, value) {
selectedData.push(selectedIndexes[index].id);
});
now you have all the selected id's in the "selectedData" variable