Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Contact Us
Online Help
Domain Status
Man Pages

Virtual Servers

Topology Map

Server Agreement
Year 2038

USA Flag



Man Pages

Manual Reference Pages  -  JQUERY::TREEVIEW (3)

.ds Aq ’


JQuery::Treeview - shows a information as a tree.



Version 1.00


JQuery::Treeview shows a information as a tree.

    use JQuery;
    use JQuery::Treeview;

    my $list =<<EOD;
 folder 1(fc)
  file 1.1
  file 1.2
  file 1.3
  folder 1.2(f)
   file 2.1
   file 2.2
   file 2.3
   folder 1.3(fc)
    folder 1.4(f)
   file 1.4
 folder 2(f)
  file 2.1
 folder 3(f)

   my $tree = JQuery::Treeview->new(list => $list,
                                 id => mytree,
                                 separator => "/",
                                 addToJQuery => $jquery,
                                 treeControlId => myTreeControl,
                                 treeControlText => [Collapse All,Expand All,Toggle All],
                                 defaultState => open,
                                 highlightNodes => 1,
                                 highlightLeaves => 1,
                                 highlightUnderline => 1,
                                 type => directory,
                                 rm => MyTreeView,
                                 debug => 0,
                                 remoteProgram => /cgi-bin/ ;
    my $htmlControl = $tree->HTMLControl ;
    my $html = $tree->HTML ;


Treeview shows data in a tree format. For an example see <>

The simplest way to present the data is in the format shown above. Each indentation represents another level. The letters in brackets stand for
f A folder or node
c The node is initially closed
o The node is initially open
(Putting all this information in a Perl array with embedded hashes is possible, but really ugly, and hard to debug visually. I tried, but didn’t like the result.)

The other parameters are:
list The list in the format show above
id The css id of the element
separator When an item is pressed, the it and all ancestors are concatenated and sent to the calling program. The item called ’data’ contains just the data as shown at the leaf or node. ’data1’ gives the whole path, each element being separated by the separator.

In other words, you might get data=myfile, and data1=dir/dir1/dir2/myfile

addToJQuery The JQuery container
treeControlId The id of a control element. JQuery::Treeview can generate the control HTML, which is just a set of links allowing the user to manipulate the tree. The user can collapse all, expand all, and toggle all.
treeControlText These are the text items needed for the treeControlId
defaultState The default state of the tree, either open or closed.
highlightNodes If highlightNodes is set, then nodes will be underlined
highlightLeaves If highlightLeaves is set, then the leaves will be underlined
type If type is ’directory’, the folder and file icons will be used in the display. If the type is gray, red or black no icons are used.
rm This is the runmode to be used when running an external program
remoteProgram This is the name of the remote program to be used when an item is pressed.


new Instantiate the object.
HTML Produce the HTML code
HTMLControl Produce the HTML code for the control


Peter Gordon, <peter at>


Please report any bugs or feature requests to bug-jquery-taconite at, or through the web interface at <>. I will be notified, and then you’ll automatically be notified of progress on your bug as I make changes.


You can find documentation for this module with the perldoc command.

    perldoc JQuery

You can also look for information at:
o AnnoCPAN: Annotated CPAN documentation


o CPAN Ratings


o RT: CPAN’s request tracker


o Search CPAN




Copyright 2007 Peter Gordon, all rights reserved.

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

Search for    or go to Top of page |  Section 3 |  Main Index

perl v5.20.3 JQUERY::TREEVIEW (3) 2016-03-17

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with manServer 1.07.