tags:

views:

128

answers:

1

Anyone out there who's knows the JsTree jQuery plugin well?

I have implemented it and got it working ok for most basic functionality, but now I want to be able to use the functionality for removing and creating new folders. I can't find information about how to do this in the documentation.

Here's how I use it right now: $("#divLeftPane") .bind("reselect.jstree", function () {

                if ($(".jstree-clicked").length == 0)
                    url = "";
                else
                    url = "?url=" + $(".jstree-clicked").attr("rel");
                loadFiles(url);
                $("#currentDir").val($(".jstree-clicked").attr("rel"));


                $("a").click(function () {
                    url = "?url=" + $(this).attr("rel");
                    loadFiles(url);
                    $("#currentDir").val($(this).attr("rel"));
                });
            }).jstree({
                "html_data": {
                    "ajax": {
                        "url": "/Customers/Directories/"
                    }
                },
                "ui": {
                    "select_limit": 2,
                    "select_multiple_modifier": "alt",
                    "selected_parent_close": "select_parent"//,
                    //                  "initially_select": ["phtml_2"]
                },
                "themes": {
                    "theme": "classic",
                    "dots": false,
                    "icons": true
                },

                "plugins": ["themes", "html_data", "ui", "cookies"]
            });
};
A: 

Oops, didn't read the docs carefully enough, it was under one of the plugins named CRRM (maybe the name threw me off a bit :-)) http://www.jstree.com/documentation/crrm

Anders Svensson