Panel.prototype.getRawObject = function(obj) {
     var theObj;
     
     if (typeof obj == "string") {
        if (this.isW3C) {
           theObj = document.getElementById(obj);
        } else if (this.isIE4) {
           theObj = document.all(obj);
        } else if (this.isNN4) {
           theObj = seekLayer(document, obj);
        }
     } else {
        // pass through object reference
        theObj = obj;
     }
     return theObj;
  };
  function Panel(szID ) {
     this.isCSS = false;
     this.isW3C = false;
     this.isIE4 = false;
     this.isNN4 = false;
     this.isIE6CSS = false;
  
     if (document.images) {
        this.isCSS = (document.body && document.body.style) ? true : false;
        this.isW3C = (this.isCSS && document.getElementById) ? true : false;
        this.isIE4 = (this.isCSS && document.all) ? true : false;
        this.isNN4 = (document.layers) ? true : false;
        this.isIE6CSS = (document.compatMode && document.compatMode.indexOf("CSS1") >= 0) ? true : false;
     }
     this.domObj = this.getRawObject(szID);
     this.width=getObjectWidth(this.domObj);
     this.height=getObjectHeight(this.domObj);
     this.initialize();
  };
  
  Panel.prototype.initialize = function(id) {
     call('prova.php',this,this.draw);
  };
  
  Panel.prototype.draw = function( szResult ) {
  
     //clear old div
     for(var i = this.domObj.childNodes.length - 1; i >= 0; i--) {
        this.domObj.removeChild (this.domObj.childNodes[i]);
     }
  
     var text = document.createElement( 'div' );
     text.id="newPanelText";
     text.innerHTML = szResult;
     this.domObj.appendChild(text);
};
