//레이어 출력 여부결정
var eventPopupCount = 0;
function Event_Popup(idx,pWith,pHeight) {
   if ( getCookie( "Notice"+idx ) != "done" ) 
	{

		popupwidth = pWith;
		popupheight = pHeight;
		LeftPosition = (screen.width) ? (screen.width-popupwidth)/2 : 0;
		TopPosition = (screen.height) ? (screen.height-popupheight)/2 : 0;

		if (eventPopupCount == 0)
		{
			LeftPosition = LeftPosition - (pWith/2);
		}
		else
		{
			LeftPosition = LeftPosition + (pWith/2);
		}
		settings = 'height='+ popupheight +',width='+popupwidth+',top='+TopPosition+',left='+LeftPosition+',scrollbars=no, resizable=no, location=no';

		window.open('/popup/Notice' + idx + '.html','Notice',settings);

		eventPopupCount++;
	}  
}


//레이어 감추기
function Event_closewin(idx) 
{ 
        if ( $("#Notice" + idx).is(":checked") ) 
		{
                setCookie( "Notice"+idx, "done" , 1); 
		}
        
		self.close();
        //document.all["P_Layer" + idx].style.display="none";
} 


