function FWS_Ajax(){this.mimeType ='text/plain; charset=UTF-8';this.xmlHttp =null; this.onStart =function() {};this.onFinish =function() {};this._prepare_request =function(onfinish) {	if(this.xmlHttp ==null ||Browser.isIE) this.xmlHttp =FWS_getXmlHttpObject(); var cxmlHttp =this.xmlHttp; var conFinish =this.onFinish; 	if(!cxmlHttp) return; this.onStart();   	if(Browser.isIE &&cxmlHttp.overrideMimeType) cxmlHttp.overrideMimeType(this.mimeType); var callback=function() {	if(cxmlHttp.readyState ==4||cxmlHttp.readyState =='complete'){onfinish(cxmlHttp.responseText); conFinish(); }};cxmlHttp.onreadystatechange =callback;};this.setMimeType =setMimeType; this.setEventHandler =setEventHandler; this.sendGetRequest =sendGetRequest; this.sendPostRequest =sendPostRequest; }function setMimeType(mimeType) {this.mimeType =mimeType; }function setEventHandler(event,handler) {	if(typeof handler !='function')return; switch(event) {case 'start':case 'onstart':this.onStart =handler; break; case 'finish':case 'onfinish':this.onFinish =handler; break; }}function sendGetRequest(url,onfinish) {this._prepare_request(onfinish); this.xmlHttp.open('GET',url,true); try {this.xmlHttp.send(null); }catch(e) { }}function sendPostRequest(url,parameters,onfinish) {this._prepare_request(onfinish); this.xmlHttp.open('POST',url,true); this.xmlHttp.setRequestHeader('Content-type','application/x-www-form-urlencoded'); this.xmlHttp.setRequestHeader('Content-length',parameters.length); this.xmlHttp.setRequestHeader('Connection','close'); try {this.xmlHttp.send(parameters); }catch(e) { }}  function FWS_displayWaitBar(id,message) {	if(typeof message =='undefined')message ='Please wait';var bar =FWS_getElement(id); 	if(!bar) {var body=document.getElementsByTagName('body')[0]; var element =document.createElement('div'); element.id = id; element.align ='center';element.style.display ='none';element.innerHTML ='Please wait...';body.appendChild(element); bar =FWS_getElement(id); }var pageSize =FWS_getPageSize(); var width =pageSize[0]; bar.style.display ='block';bar.style.width =width +'px';bar.style.top ='0px';bar.style.position ='fixed';}function FWS_getXmlHttpObject() {var req =null; 	if(typeof XMLHttpRequest !="undefined")req =new XMLHttpRequest(); 	if(!req &&typeof ActiveXObject !="undefined"){try {req =new ActiveXObject("Msxml2.XMLHTTP"); }catch(e) {try {req =new ActiveXObject("Microsoft.XMLHTTP"); }catch(e2) {try {req =new ActiveXObject("Msxml2.XMLHTTP.4.0"); }catch(e3) {req =null; }}}}	if(!req &&window.createRequest) req =window.createRequest(); return req; }
