I would like to automatically open a node in the tree on the left (id=JTree). It appears that I can just set a class of "open" or "closed" (at least as I test it through firebug). I tried the following jQuery in the ready block of TreeControl.ascx:
jQuery("#JTree ul li ul li").removeClass("closed").addClass("open"); // #fail
Testing further I found the following (jquery test) works fine, until I get down below the JTree element and then it fails on everything after that:
From this I can conclude that jquery is there and working. I am navigating down the tree correctly with jquery selectors. All I can think is that may it is some kind of a timing thing where the jQuery.UmbracoTree isn't done loading yet???
All of the above code is in the ready block of /Umbraco/Controls/Tree/TreeControl.ascx. Any help would be much appreciated.
Thanks,
James J
P.S. Is there any documentation on JTree? I am using v4.11.3.1 and can't seem to find much info about TreeControl.ascx or JTree.
How to get JTree to open node?
Umbraco: v4.11.3.1
I would like to automatically open a node in the tree on the left (id=JTree). It appears that I can just set a class of "open" or "closed" (at least as I test it through firebug). I tried the following jQuery in the ready block of TreeControl.ascx:
jQuery("#JTree ul li ul li").removeClass("closed").addClass("open"); // #fail
Testing further I found the following (jquery test) works fine, until I get down below the JTree element and then it fails on everything after that:
jQuery("body #uiArea #JTree").addClass("ncaatourney"); // #works
jQuery("body #uiArea #JTree ul").addClass("ncaatourney"); // #fail
From this I can conclude that jquery is there and working. I am navigating down the tree correctly with jquery selectors. All I can think is that may it is some kind of a timing thing where the jQuery.UmbracoTree isn't done loading yet???
All of the above code is in the ready block of /Umbraco/Controls/Tree/TreeControl.ascx. Any help would be much appreciated.
Thanks,
James J
P.S. Is there any documentation on JTree? I am using v4.11.3.1 and can't seem to find much info about TreeControl.ascx or JTree.
is working on a reply...