comment obtenir une liste des identifiants vérifiés de jstree avec checkbox plugin?comment obtenir une liste des ids vérifiés de jstree avec checkbox plugin?
3
A
Répondre
0
var result = new Array();
$(".jstree-checked").each(function(i, element){
result[i] = $(element).attr("id");
});
-1
http://www.jstree.com/documentation/checkbox
.get_checked (context, get_all), .get_unchecked (context, get_all)
(au bas de cette page)
0
var arr = new Array();
var i = 0;
$('#dtree_region li').filter('.jstree-checked').each(function(){
arr[i] = $.makeArray($(this).attr("id"));
// sel_id = sel_id + ',' + $(this).attr("id");
i++;
});
var sel_id = arr.join(",");
FYI: ce ne sera pas le retour des enfants d'articles vérifiés. –