function hiddenDIV(){
//	var divOpaco2 = document.getElementById("opaco");
	var divImage2 = document.getElementById("NOopaco");
	
	divImage2.innerHTML = '';
	divImage2.style.display="none";
	//divOpaco2.style.display="none";
}

function showDIVGallery(id_caso,pagina){
	WinWidth=(document.layers)?window.innerWidth:window.document.body.clientWidth;
    WinHeight=(document.layers)?window.innerHeight:window.document.body.clientHeight;
	
  	var myHeight = 0;
	  if( typeof( window.innerWidth ) == 'number' ) {
		//Non-IE
		myHeight = window.innerHeight;
	  } else if( document.documentElement && ( document.documentElement.clientWidth || document.documentElement.clientHeight ) ) {
		//IE 6+ in 'standards compliant mode'
		myHeight = document.documentElement.clientHeight;
	  } else if( document.body && ( document.body.clientWidth || document.body.clientHeight ) ) {
		//IE 4 compatible
		myHeight = document.body.clientHeight;
	}

	if (myHeight>WinHeight) WinHeight = myHeight;



	var iebody=(document.compatMode && document.compatMode != "BackCompat")? document.documentElement : document.body;
	var dsocleft=document.all? iebody.scrollLeft : pageXOffset;
	var dsoctop=document.all? iebody.scrollTop : pageYOffset;

	
	var divImage = document.getElementById("NOopaco");
	
	divImage.style.display="block";
	divImage.style.top = '0px';   
	
	var marginLeft = ((WinWidth-660)/2);
	var marginTop = dsoctop+30;

	divImage.style.margin=marginTop+"px 0px 0px "+marginLeft+"px";
	
	var HeightIMG = (myHeight - 100);

	divImage.style.width = '660px';
		
//	var b = document.getElement.ById("bodyPage");
//	b.
//	window.onscroll(alert('asdasd'));

//	divOpaco.style.width = WinWidth+'px';
//	divOpaco.style.height = WinHeight +'px';
		
		
	doOP("/backoffice/cms/layouts/Casi/gallery.jsp","id="+id_caso+"&pg="+pagina);

}

function moveImg(){
	var divImage = document.getElementById("NOopaco");

	if(divImage.style.display == 'block'){
		var iebody=(document.compatMode && document.compatMode != "BackCompat")? document.documentElement : document.body;
		var dsoctop=document.all? iebody.scrollTop : pageYOffset;
		divImage.style.marginTop=dsoctop+30+"px";	
	}
}


