JavaScript Adding Elements to a Tree with TreeView jQuery |
Naturally, if you've read the previous installment of this series, it's quite possible that you already have a clear idea of how to utilize the great variety of options offered by this plug-in to create truly dynamic hierarchical trees. In that specific article, I explained how to use the "persist" parameter to easily save the state of a given tree across several HTTP requests. In reality, the "persist" option takes two possible values. The first one, called "location," allows you to maintain the settings of the tree via the "href" attributes of the hyperlinks that comprise it, while the second one, identified as "cookie," obviously saves the tree's state by using some cookies. However, it's worth mentioning that the "TreeView" plug-in offers an additional feature, named "add," that deserves a close analysis. It can be employed to dynamically add elements to a selected tree. Therefore, in this last chapter of the series I'm going to discuss how to work with it, thus finishing this introductory overview to this powerful jQuery plug-in. Ready to tackle the final episode of this educational journey? Then let's get going!
blog comments powered by Disqus |