function doHttpRequest(url,contentId,method,parameters,postFunction){ if(method==''){ method = 'GET' } poststr = ''; if(typeof(parameters)=='object' && parameters.length>0){ for(i=0;i'; } httpRequest.onreadystatechange = function() { refreshHttpContent(httpRequest,contentId,postFunction); }; httpRequest.open(method, url, true); if(method=='POST'){ httpRequest.setRequestHeader("Content-type", "application/x-www-form-urlencoded"); httpRequest.setRequestHeader("Content-length", poststr.length); httpRequest.setRequestHeader("Connection", "close"); httpRequest.send(poststr); }else{ httpRequest.send(''); } } function refreshHttpContent(httpRequest,contentId,postFunction) { if (httpRequest.readyState == 4) { if (httpRequest.status == 200) { regExpFunc = /jsFunction:.*/ regExpCode = /jsCode/ if(contentId.match(regExpFunc)){ funcName = contentId.replace('jsFunction:','') eval(funcName+'("'+escape(httpRequest.responseText)+'")') }else if(contentId.match(regExpCode)){ eval(httpRequest.responseText) }else{ document.getElementById(contentId).innerHTML = httpRequest.responseText; } if(postFunction!=''){ eval(postFunction); } } else { alert('There was a problem with ajax: the browser received a response '+httpRequest.status); } } } var win=null; function OpenNewWindow(mypage,myname,w,h,scroll,pos,resiz) { if(resiz!="yes") { resiz = 'no'; } if(pos=="random") { LeftPosition=(screen.width)?Math.floor(Math.random()*(screen.width-w)):100; TopPosition=(screen.height)?Math.floor(Math.random()*((screen.height-h)-75)):100; } if(pos=="center") { LeftPosition=(screen.width)?(screen.width-w)/2:100; TopPosition=(screen.height)?(screen.height-h)/2:100; } if(pos=="top") { LeftPosition=20; TopPosition=20; } else if((pos!="center" && pos!="top" && pos!="random") || pos==null) { LeftPosition=0; TopPosition=20 } settings='width='+w+', height='+h+', top='+TopPosition+', left='+LeftPosition+', scrollbars='+scroll+', location=no, directories=no, status=no, menubar=no, toolbar=no, resizable='+resiz; win=window.open(mypage,myname,settings); if(win.focus) { win.focus(); } } var NaviWin; function NavigaWin(pagina, l, a) { NaviWin=window.open(pagina,'','toolbar=no,left=50,top=80,directories=no,status=no,menubar=no,scrollbars=no,resizable=no,copyhistory=no,width=' + l +',height=' + a); } function CloseNewWindow() { if(win!=null && win.open) win.close() } function DeleteRecord(url){ if(strtodisplay==""){ strtodisplay = "E' sicuro di voler cancellare il record specificato?"; } if(confirm(strtodisplay)){ location = url; } return true; } function MM_swapImgRestore() { //v3.0 var i,x,a=document.MM_sr; for(i=0;a&&i0&&parent.frames.length) { d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);} if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i"; testo += ""; testo += ""; testo += document.getElementById(div_id).innerHTML+""; testo += "