Solved

JsTree loading data

Posted on 2014-04-02
1
7,525 Views
Last Modified: 2014-04-13
I've been reading up on using jsTree and trying to figure out how to load data into the tree. My data I want to load is massive so I will need to use ajax, so when a node is clicked on I want it to go off and pull in the child nodes.

Ive seen some examples of binding to the click event then going off to pull the child nodes back however Im unable to find any examples how to bind on click of the node, change the icon to a 'waiting gif' and then pull down an ajax json request and draw child nodes showing which ones can expand and bind expandable nodes to draw more.

Anyone got any examples or any documentation on binding to a node and drawing child nodes from the json returned request?

Thank you for any assistance anyone can provide
0
Comment
Question by:tonelm54
1 Comment
 
LVL 22

Accepted Solution

by:
Mrunal earned 500 total points
ID: 39977914
Hi
have you gone through this link:
http://www.jstree.com/demo/
?

it has all examples having ajax call, load json data, etc.

Also check this example:
http://johntang.github.io/JsTree/demo.html

http://www.miketyka.com/2012/10/lazy-loading-with-jstree-and-ajax/
0

Featured Post

6 Surprising Benefits of Threat Intelligence

All sorts of threat intelligence is available on the web. Intelligence you can learn from, and use to anticipate and prepare for future attacks.

Join & Write a Comment

by Julian Matz As of jQuery (http://jquery.com/) 1.4 the .live() method (http://api.jquery.com/live/) supports custom events as well as some standard JavaScript events that it previously didn't support. Among these is the submit event. Unlike …
This article discusses how to create an extensible mechanism for linked drop downs.
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

757 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now