
function modalWin(url,name, width, height) {
	var left = (screen.width/2)-(width/2);
	var top = (screen.height/2)-(height/2);
	if (window.showModalDialog) {
		//IE
		var modalReturnValue=window.showModalDialog(url,name,"dialogWidth:"+width+"px;dialogHeight:"+height+"px;dialogTop:"+top+"px;dialogLeft:"+left+"px;"+"scroll:no;");
		 if ( (modalReturnValue == undefined) || (modalReturnValue == '') )
		 {
		  // No results sent or user clicked the 'X' closer...
		 }
		else
		{
		 // dialogResult is the value returned from the dialog...
		 // alert(modalReturnValue);
		 window.location.href = modalReturnValue;
		}
	}
	else {
		//Firefox and others
		window.open(url,name,
		'height='+height+',width='+width+',toolbar=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no ,modal=yes,top='+top+',left='+left);
	}

} 

 function keepMeAlive(imgName){    
	myImg = document.getElementById(imgName);     
	if (myImg)  
    	myImg.src = myImg.src.replace(/\?.*$/, '?' + Math.random());     
 }     

