function ajaxrequest(getfile,getparam,getid,loading){ // (file,yourparam=value&~~,id,0/1);
	if(loading==1){
		document.getElementById(getid).innerHTML="Loading...";
	}

	var req;
	if(window.XMLHttpRequest){
		// for other browser not IE
		req=new XMLHttpRequest();
	}
	else if(window.ActiveXObject){
		// for IE
		req=new ActiveXObject("Microsoft.XMLHTTP");
	}else{
		alert("Browser Error");
		return false;
	}
	req.onreadystatechange=function(){
		if(req.readyState==4 && req.status==200){
			document.getElementById(getid).innerHTML=req.responseText;
		}
	}
	req.open("GET",getfile+"?rand="+Math.random()+"&"+getparam,true);
	req.send(null);
}// end ajexRequest funtion


function RequestCalendar(getyear,getmonth,getid){
	ajaxrequest("../request_calendar.php","y="+getyear+"&m="+getmonth,"ds_calendar",0);
}

function Balloon_show(getactiveid,getparam){
	//alert(getactiveid+" - "+getparam);
	var posx=0,posy=0;

	if(event.pageX || event.pageY){
		posx=event.pageX; posy=event.pageY;
	}
	else if(event.clientX || event.clientY){
		if(document.documentElement.scrollTop){
			posx=event.clientX+document.documentElement.scrollLeft;
			posy=event.clientY+document.documentElement.scrollTop;
			}
		else{
			posx=event.clientX+document.body.scrollLeft;
			posy=event.clientY+document.body.scrollTop;
			}
	}

	document.getElementById(getactiveid).innerHTML=getparam;
	document.getElementById(getactiveid).style.visibility='visible';
	document.getElementById(getactiveid).style.left=(posx-document.getElementById('balloon').offsetWidth)+9+"px";
	document.getElementById(getactiveid).style.top=(posy+14)+"px";
}

function Balloon_hide(getactiveid){
	document.getElementById(getactiveid).style.visibility='hidden';
}


function ConfDelete(){
	if(confirm('Do you want Delete ?')==true){
		return true;
	}else{
		return false;
	}
}