Home > Web Front-end > JS Tutorial > body text

Struts2 jquery creates infinite levels of trees_jquery

WBOY
Release: 2016-05-16 18:43:46
Original
1176 people have browsed it








//Required :Struts2, jquery tree plug-in, its download address is: http://xiazai.jb51.net/200910/other/jquery.treeview.zip
//Infinite-level tree--Author Ren Wenmin of Chenzhou Tuozhi Software College
//Simulated database data: Each row of data includes--own ID, own content, father ID
ArrayList ary = new ArrayList(); //All data
String[] ary1 = new String[] {"1","item1","0"}; //Each row of data
ary.add(ary1);
ary1 = new String[]{"2","item2","0" };
ary.add(ary1);
ary1 = new String[]{"3","item3","0"};
ary.add(ary1);
ary1 = new String[]{"4","item1_1","1"};
ary.add(ary1);
ary1 = new String[]{"5","item1_2","1"} ;
ary.add(ary1);
ary1 = new String[]{"6","item1_2_1","5"};
ary.add(ary1);
ary1 = new String[]{"7","item1_2_2","5"};
ary.add(ary1);
ary1 = new String[]{"8","item2_1","2"};
ary.add(ary1);
ary1 = new String[]{"9","item2_1_1","8"};
ary.add(ary1);
ary1 = new String []{"10","item2_2","2"};
ary.add(ary1);
ary1 = new String[]{"11","item3_1","3"};
ary.add(ary1);
ary1 = new String[]{"12","item3_2","3"};
ary.add(ary1);
request.setAttribute(" datas",ary);
%>


    jquery tree plug-in, its download address is: http://xiazai.jb51.net/200910/other/jquery.treeview.zip
    Related labels:
    source:php.cn
    Statement of this Website
    The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
    Popular Tutorials
    More>
    Latest Downloads
    More>
    Web Effects
    Website Source Code
    Website Materials
    Front End Template