posted 20 years ago
Hi!!
I have got one source file of javascript function.
I have included it at between my <head> </head> for the document.
Basically it gives you some functios to call so as to create
the lists in tree form like:-
myList.sub[0]= new sub ('a');
myList.sub[1] = new sub ('b');
myList.sub[1].sub[0] = new sub ('ba');
myList.sub[1].sub[1] = new sub ('bb');
myList.sub[2] = new sub('c');
Then I call the (createList(myList)), which in turn produces this list.
I have done this code inside a script. Up to this every thing is fine.
Now I want to link say myList.sub[2] with some link (say, javascript:loadLists(myList)) and write the javascript function loadList like:-
<script language ="JavaScript"><!--
myList.sub[3] = new sub('d');
createList(myList);
-->
</script>
But this doesn't work. Whenever I click on the link, nothing appears on the page.
Are the infos given, is sufficient to help me out? If no, plz. write, so I'll send the codes also.
Thanks