load: function(url, vars) {
var urlScript = 'cat-xml.php?cPath=' + (this.id);
//window.alert('attempting to load: ' + urlScript);
new Ajax(urlScript, {
method: 'get',
evalScripts: true,
update: $('loadXML')
}).request();
//window.alert('completed phpscript using ' + urlScript)
if (this.loading) return; // if this node is already loading, return
this.loading = true; // flag this node as loading
this.toggle(false, true); // expand the node to make the loader visible
this.clear();
this.insert(this.control.loader);
//window.alert('loading xml based on ' + urlScript)
var f = function() {
new XHR({
method: 'GET',
onSuccess: this._loaded.bind(this),
onFailure: this._load_err.bind(this)
}).send(url, vars || '');
};
//window.alert('found and successfull - now loading the xml file')
window.setTimeout(f.bind(this), 2000); // allowing a small delay for the browser to draw the loader-icon.
},