var siteLocation = "e:\\Genealogie\\Website";

function doReplaceLocation(pssiteName) {

	var lcURL = new String(top.document.URL).toLowerCase();
	var lcLoc = new String(siteLocation).toLowerCase();
	var lcSiteName = new String(pssiteName).toLowerCase()
	var lcSubURL1 = "gd-hoofd.htm";
	var lcSubURL2 = "gd-index.htm";

	var noReload = false;
	
	// ico gd-hoofd.htm
	var i = findFirstPos(lcURL, lcSubURL1);
	if ((i>-1) && (noReload !=true)){
		//alert ("hoofdpagina is fout geladen");
		top.location.replace("frames.htm");
	} else {
		// alert ("hoofdpagina is goed geladen");
	}
	
	// ico gd-index.htm
	var i = findFirstPos(lcURL, lcSubURL2);
	if ((i>-1) && (noReload !=true)){
		//alert ("indexpagina is fout geladen");
		top.location.replace("frames.htm");
	} else {
		// alert ("indexpagina is goed geladen");
	}
}

function findFirstPos(pString, pSearch){
	var iPos = -1;
	iPos = pString.search(pSearch);
	return iPos;
}
