if(!action)
action='javascript:'+this.handle+'.toggle("'+id+'");';
+ var actionref;
+ if( typeof action == 'string' )
+ actionref = elem('a',{href:action}, name);
+ else {
+ actionref = elem('a',{href:'javascript:void(0);'}, name);
+ actionref.onclick = action;
+ }
+
var div = elem('div',{id:id});
var topdiv = elem('div',{style:'vertical-align:middle'});
var link = elem('a', {id:'stlink_' + id});
- var actionref = elem('a',{href:action}, name);
var contdiv = elem('div',{id:'stcont_' + id});
if(cls) addCSSClass(actionref, cls);
- actionref.setAttribute('href',action);
+ //actionref.setAttribute('href',action);
if(title) actionref.setAttribute('title',title);
else actionref.setAttribute('title',name);
SlimTree.prototype.open = function(id) {
if($(id).getAttribute('ostate') == '2') return;
var link = $('stlink_' + id);
+ if(!link) return;
if(id != this.rootid || !this.rootimg) {
removeChildren(link);
_apc(link,stimgclose.cloneNode(true));
SlimTree.prototype.close = function(id) {
var link = $('stlink_' + id);
+ if(!link) return;
if(id != this.rootid || !this.rootimg) {
removeChildren(link);
_apc(link,stimgopen.cloneNode(true));