	function sokanket(){
		wo("sokanket/index.html", 600, 500);
	}
	
	//open popup window 
	function wo(path, width, height){
		winwidth=width+40;
		winheight=height+20;
		x=window.open(path, 'y','width='+winwidth+', height='+winheight+', toolbars=no, scrollbars=yes, resizable=yes, top='+((screen.height-winheight)/2)+ ', left='+((screen.width-winwidth)/2) );
	}
	
	
	function showLayer(lotteryDivId){
		divObj = document.getElementById(lotteryDivId);
		divObj.style.display = (divObj.style.display=='')? 'none':''; 
	}
	
	/**************************************/
 
PositionX = 100;
PositionY = 100;

// Set these value approximately 20 pixels greater than the
// size of the largest image to be used (needed for Netscape)

defaultWidth  = 500;
defaultHeight = 500;
 
if (parseInt(navigator.appVersion.charAt(0))>=4){
	var isNN=(navigator.appName=="Netscape")?1:0;
	var isIE=(navigator.appName.indexOf("Microsoft")!=-1)?1:0;
	var isOP=(navigator.userAgent.indexOf('Opera')!=-1)?1:0;
}

var optNN='scrollbars=no,resizable=no,toolbar=no,location=no,status=no,menubar=no';//,width='+defaultWidth+',height='+defaultHeight+',left='+PositionX+',top='+PositionY;
var optIE='scrollbars=no,resizable=no,toolbar=no,location=no,status=no,menubar=no';//,width=150,height=100,left='+PositionX+',top='+PositionY;
var optOP='scrollbars=no,resizable=no,toolbar=no,location=no,status=no,menubar=no';

var AutoClose = true;
//function popImage(imageURL,imageTitle){
	function openImage(imageURL){
		imageTitle="Sok";
		if (isNN){imgWin=window.open('about:blank','',optNN);}
		if (isIE){imgWin=window.open('about:blank','',optIE);}
		if (isOP){imgWin=window.open('about:blank','',optOP);}
		with (imgWin.document){
			//alert(navigator.appVersion);
			//alert(navigator.appName);
			writeln('<html><head><title>Loading...</title><style>body{margin:0px;}</style>');
			writeln('<sc'+'ript>');
			writeln('	var isNN,isIE,isOP;');
			writeln('	if (parseInt(navigator.appVersion.charAt(0))>=4){');
			writeln('		isNN=(navigator.appName=="Netscape")?1:0;');
			writeln('		isIE=(navigator.appName.indexOf("Microsoft")!=-1)?1:0;');
			writeln('		isOP=(navigator.userAgent.indexOf("Opera")!=-1)?1:0;');
			writeln('	}');
			
			writeln('	function reSizeToImage(){');
			writeln('		if (isIE){');
			//writeln('			window.resizeTo(100,100);');
			//writeln('			width=100-(document.body.clientWidth-document.images[0].width);');
			//writeln('			height=100-(document.body.clientHeight-document.images[0].height);');
			writeln('			width=document.images[0].width+5;');
			writeln('			height=document.images[0].height+70;');
			writeln('			window.resizeTo(width,height);');
			writeln('		}');
			
			writeln('		if (isNN){');       
			//writeln('			alert("Fire");');
			writeln('			window.innerWidth=document.images["George"].width;');
			writeln('			window.innerHeight=document.images["George"].height;');
			writeln('			width=document.images["George"].width+5;');
                        writeln('			height=document.images["George"].height+70;');
			writeln('			window.resizeTo(width,height);');
			writeln('		}');
			
			writeln('		if (isOP){');
                        //writeln('			alert("Opera");');
                        writeln('                       window.innerWidth=document.images["George"].width;');
                        writeln('                       window.innerHeight=document.images["George"].height;');
                        writeln('                       width=document.images["George"].width+5;');
                        writeln('                       height=document.images["George"].height+70;');
                        writeln('                       window.resizeTo(width,height);');
			writeln('               }');
			writeln('	}');

			writeln('function doTitle(){document.title="'+imageTitle+'";}');
	
			writeln('</sc'+'ript>');
			if (!AutoClose) writeln('</head><body bgcolor=000000 scroll="no" onload="reSizeToImage();doTitle();self.focus()">')
			else writeln('</head><body bgcolor=000000 scroll="no" onload="reSizeToImage();doTitle();self.focus()">');//onblur="self.close()"
			writeln('<img name="George" src='+imageURL+' style="display:block"></body></html>');
			close();		
		}
	}
	
	
	function calCellOnClick(status, param1){		
		if(status=='goto'){
			nDate=document.frm1.new_newspaper_date;
			location.href='index.jsp?n='+nDate.value;
		}
	}




	

