function popWindow(winLink, wWidth, wHeight, res, scr)
{
	var winWidth 	= wWidth + 20; 
	var winHeight 	= wHeight + 20;
    var winName 	= 'popup';
    
	if(scr){
		scrollbar = ', scrollbars=yes'; 
	} else { 
		scrollbar = ', scrollbars=no'; 
	}; 
	
	if(res){
		resizable = ', resizable=yes'; 
	} else { 
		resizable = ', resizable=no'; 
	}; 
	
   
	var winX = (window.screen.width / 2) - (winWidth / 2);
	var winY = (window.screen.height / 2) - (winHeight / 2);
	var popup= window.open("", winName, "width="+winWidth+", height="+winHeight+resizable+scrollbar+", left="+winX+", top="+winY);
	
	popup.document.location = winLink; 
	popup.self.focus();
};
