function OpenWin(sUrl, sName, sTitle, iWidth, iHeight)
{
	
	//var sTitle="Antiek galerie 'Aan de Brummelkant'";
	var sLoadMessage="<B> Bezig met laden ...<\/B>";
	var iCenterFactor=50;
	var iVertCenterFactor=10;
	var sCSSFile="../css/main.css";
	var sScrollB="no";

	// Add marges
	iHeight+=20; iWidth+=20;
	// In het midden van het scherm tonen.
	var iTop = (screen.height/2) - (iHeight/2)- 50;
	var iLeft = (screen.width/2) - (iWidth/2);
	
	// Also increase height respectively width since we have to take in account: an scrollbar (when applicapable)
	if(iWidth>screen.width-60) { iWidth=screen.width-60; iHeight+=20; sScrollB="yes"; }
	if(iHeight>screen.height-60) { iHeight=screen.height-60; iWidth+=20; sScrollB="yes"; }
	
	windowHandle = window.open("", sName, 'width='+iWidth+',height='+iHeight+',resizable=no,status=no,menubar=no,scrollbars=no,top='+iTop+',left='+iLeft+'');

	var sPage="<HTML><HEAD><TITLE>"+sTitle+"<\/TITLE><LINK REL=\"stylesheet\" href=\""+sCSSFile+"\"><\/HEAD><BODY bgcolor=\"#003366\" LEFTMARGIN=\"10\" TOPMARGIN=\"10\"><DIV STYLE=\"position: absolute; left: "+(iWidth/2-iCenterFactor)+"px; top:"+(iHeight/2-iVertCenterFactor)+"px; z-index:-10\">"+sLoadMessage+"<\/DIV><DIV STYLE=\"z-index:10\"><IMG ONLOAD=\"document.title='"+sTitle+"'; opener.bImgLoaded=true\" SRC=\""+sUrl+"\"><\/DIV><\/BODY><\/HTML>";

	
	windowHandle.document.open();
	windowHandle.document.write(sPage);
	windowHandle.document.close();
}
