// ========== Site Variables ====================
var zTopPage		= 'index.php';
var zMenuPage		= 'menu.html';
var zDefaultPage	= 'home.php';
var zEmptyPage		= 'niks.html';
var zMenuFrame		= 'menu';
var zDefaultFrame	= 'inhoud';
var zPageSeperator	= 'page=';
// ========== Einde Site Variables ==============


// ========== Top Frame Code =======================
function zBreakFrames()
	{
	if (window != top)
		top.location.replace(location);
	}

function zLoadPageInFrames()
	{
	var url = top.location.search.substr(1);
	var idx = url.indexOf(zPageSeperator);
	if (idx != -1)
		{
		var page = url.substr(idx + zPageSeperator.length);
		if (page != '' && typeof(frames[zDefaultFrame]) != 'undefined')
			{
			frames[zDefaultFrame].location.replace(page);
			}
		}
	}

// laat fotos zien in nieuwe window
var spaceX	= (screen.availWidth != null)	? screen.availWidth	 : screen.width;
var spaceY	= (screen.availHeight != null)	? screen.availHeight : screen.height;
var firstX	= (screen.availLeft != null)	? screen.availLeft	 : 0;
var firstY	= (screen.availTop != null)		? screen.availTop	 : 0;
var posX	= Math.floor( (spaceX - 30) / 2 - 260 );
var posY	= Math.floor( (spaceY - 30) / 2 - 280 );
var fotoWindow;

function fotoGroot(album_id, fotos_id)
	{
	var pagina = 'foto_groot.php?album_id=' + album_id + '&fotos_id=' + fotos_id;
	if (typeof(fotoWindow) != 'undefined' && !fotoWindow.closed)
		fotoWindow.close();
	winProps = 'height=580,width=520,left=' + posX + ',top=' + posY;
	fotoWindow = window.open(pagina,'fotoWindow',winProps);
	}
