function image_rotate(param) {
	show_image++;
	var req = getXmlHttp2()  
	req.onreadystatechange = function() {  
		if (req.readyState == 4) { 
			if(req.status == 200) { 
				return true;
			}else{
				//document.getElementById(layer).innerHTML='Error check';
				return false;
			}
		}

	}
	req.open('GET', '/check.php?rotate=1&'+param+"&show_image="+show_image, true);  
	req.send(null);  // отослать запрос
}

function getXmlHttp2(){
	  var xmlhttp;
	  try {
	    xmlhttp = new ActiveXObject("Msxml2.XMLHTTP");
	  } catch (e) {
	    try {
	      xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
	    } catch (E) {
	      xmlhttp = false;
	    }
	  }
	  if (!xmlhttp && typeof XMLHttpRequest!='undefined') {
	    xmlhttp = new XMLHttpRequest();
	  }
	  return xmlhttp;
}

function language_show(id){
    if(id==1) document.getElementById("lang").style.display="block";
    else document.getElementById("lang").style.display="none";
}

function PopupHide(){ document.getElementById("PopupContainer").style.display="none"; return false;}
function PopupOpen(){ document.getElementById("PopupContainer").style.display="block"; return false;}

