/** * @ author Kheygetyan Ivan * @ date 04-02-2007 1:11 AM * @ version 1.0.0 **/ /* var xmlHttp = createXmlHttpRequestObject(); function createXmlHttpRequestObject() { var xmlHttp; try { xmlHttp = new XMLHttpRequest(); } catch(e) { var XmlHttpVersions = new Array("MSXML2.XMLHTTP.6.0","MSXML2.XMLHTTP.5.0","MSXML2.XMLHTTP.4.0","MSXML2.XMLHTTP.3.0","MSXML2.XMLHTTP","Microsoft.XMLHTTP"); for (var i=0; i= 5) // JScript gives us Conditional compilation, we can cope with old IE versions. // and security blocked creation of the objects. if (!xmlHttp){ try { xmlHttp = new ActiveXObject("Msxml2.XMLHTTP"); } catch (e) { try { xmlHttp = new ActiveXObject("Microsoft.XMLHTTP"); } catch (E) { xmlHttp = false; } } } @end @*/ if (!xmlHttp && window.createRequest) { try { xmlHttp = window.createRequest(); } catch (e) { xmlHttp=false; } } var please_wait = "
Идет загрузка ...
"; function open_url(url, targetId) { if(!xmlHttp) return false; var e=parent.document.getElementById(targetId);if(!e)return false; //document.getElementById('frameViewer').style.display = "block"; e.style.display = "block"; if(please_wait)e.innerHTML = please_wait; xmlHttp.open("GET", url, true); xmlHttp.setRequestHeader("Content-Type", "application/x-www-form-urlencoded; charset=windows-1251"); xmlHttp.setRequestHeader("If-Modified-Since", "Sat, 1 Jan 2000 00:00:00 GMT"); xmlHttp.onreadystatechange = function() { response(url, e); } try { xmlHttp.send(null); } catch(l){ while(e.firstChild)e.removeChild(e.firstChild); e.appendChild(document.createTextNode("request failed")); } } function response(url, e) { if(xmlHttp.readyState != 4)return; var tmp= (xmlHttp.status == 200 || xmlHttp.status == 0) ? xmlHttp.responseText : "
ERROR
" + xmlHttp.status+" "+xmlHttp.statusText + "
"; // + location.reload() var d=document.createElement("div"); d.innerHTML=tmp; setTimeout(function(){ while(e.firstChild)e.removeChild(e.firstChild); e.appendChild(d); //CheckLoadNew(document.forms['curformBacket']); //disablePage(); },10) }