Page 1 of 1
showing tree
Posted: Fri Dec 10, 2004 1:32 am
by angelena
i would like to display my data in tree form .
The case is such as i will first display type of classes.
when click on the classes folder will display subject offer
click on subject will show lecturer involve..something like that
Class
>Subject
>>Lecturer
I duno how to put my data in order to haf it display as a tree form.
Sorry if my explanation is kinda confusing

Posted: Fri Dec 10, 2004 6:28 am
by srinu
hi
do you want to display it using PHP or HTML.
if you want display it automatically with out reloading the page, then you have to use the HTML tags div so that when the user clicks on some class
you can hide all and show that class.
or else the best way is using the PHP loops.
first diplay the classes. when the user requested class and displayed class are same then display the data over there in a different table.
thanks
Srinivas
Posted: Sun Dec 12, 2004 12:25 am
by angelena
Hi Srinu
emm..but the prob is im bit confuse how to get the data display in sequence...huhh
i think i will prefer to have it in PHP code
thx ya

Posted: Sun Dec 12, 2004 10:35 pm
by srinu
hi
first take all the classes you have read into a record set.
then write another loop for each class you have by quering the subject for the single class.
display all the subjects with in that class.
and even for the lectirer & etc also follow the sanme principle.
here first take a table for the class loop
and then with in the class <tr> take one more table to display the subjects for that class.
Srinivas
Posted: Mon Dec 13, 2004 12:21 am
by Simon
Not sure if this is helpful at all, but I love it...
http://www.destroydrop.com/javascripts/tree/
< Simon >