You give an example of an event handler in order when you cl

you give an example of an event handler in order when you click on a
node to go to a link

 
tree.setOnClickHandler(doOnClick);

function doOnClick(nodeId){

var myUrl = tree.getUserData(nodeId,‘myurl’); window.open(myUrl);

// or frames[“someframe”].location.href = myUrl

 }
 

with the window.open   if opens a
new window.

i can not find how to change it to open the link in the same window.
since I just want to navigate in my site through url (i am using variables in
the url and need to encode first in the xml file)

do we have to use this event handler when we
navigate on the same site, or is there another handler to call pages from the
same domain?

You
can use document.location to change location of current document.

function
doOnClick(nodeId){

                var myUrl =
tree.getUserData(nodeId,‘myurl’);

                document.location.href=myUrl;

}