jsTree : How to get all nodes from jstree?
问题 How to get all nodes present in jsTree? I am building jsTree with xml Root -----A -----A1 -----A1.1 -----A1.2 -----A2 -----`A2.1` -----A2.2 -----B -----B1 -----B2 -----C -----C1 -----C1.1 -----C2.2 I want array of all nodes(ID) present in jsTree is as follows Expected output: [Root, A, A1, A1.1, A1.2, A2, A2.1, A2.2, B, B1, B2, C, C1, C1.1, C2.2] 回答1: From documentation: .get_json ( node , li_attr , a_attr ) This function returns an array of tree nodes converted back to JSON. More info about