var BROWSER = navigator.appName;

 function GEBID(id) { return document.getElementById(id); } //--returns any dom element by it's id value
 function GFORM(name) { return document.forms[name]; } //--returns any html form element by it's name value


function OWIN(url, width, height, name) { //--opens a new generic window
var specs = "width="+width+",height="+height+",left=400,top=100,copyhistory=yes,directories=no,menubar=no,location=yes,resizable=yes,scrollbars=yes";
window.open(url, name, specs);
 }


//--xspark core element prototypes(Mozilla, Opera)

if(BROWSER != "Microsoft Internet Explorer") {
HTMLElement.prototype.contains = function(node) {
 if (node == null) { return false; }
 if (node == this) { return true; }
 else { 
 return this.contains(node.parentNode); 
}
}

}





