summaryrefslogtreecommitdiffstats
path: root/ecomp-portal-FE/client/bower_components/jqTree/_entries/36a_addparentnode.md
blob: 541af68c5e947f0113f6246f20485bdf1c05f075 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
---
title: addParentNode
name: functions-addparentnode
---

**function addParentNode(new_node_info, existing_node);**

Add a new node as parent of this existing node.

{% highlight js %}
var node1 = $('#tree1', 'getNodeByName', 'node1');
$('#tree1').tree(
    'addParentNode',
    {
        name: 'new_parent',
        id: 456
    },
    node1
);
{% endhighlight %}