function frameReset() 
{
	if (this.location.search) {
		// bij 'work' en 'exc' komt er een extra navigatieframe aan de linkerkant
		if (this.location.search.indexOf("work") > -1 || this.location.search.indexOf("exc") > -1) {
			bottomFrame.location.href = "/index2.html" + this.location.search;
		} else {
			bottomFrame.location.href = this.location.search.substr(1);
		}
	}
}

function updateNav(docLoc) 
{
	theCat = docLoc.substring(1, docLoc.indexOf("/",1));
	rExp = /\D+/;
	theTopButt = theCat.match(rExp);
	parent.topFrame.updateButton(theTopButt, "A");

	// thePage opslaan in globale variabele
	thePage = docLoc.substring(docLoc.indexOf("/",1)+1, docLoc.indexOf("."));
	thePage = thePage.match(rExp);
	parent.topFrame.thePage = thePage;
	
	if(bottomFrame.leftFrame)
	{
		navLoc = "/nav_" + theCat + ".html"; 
		if (bottomFrame.leftFrame.location.href.indexOf(navLoc) < 0) 
		{
			bottomFrame.leftFrame.location.href = navLoc;    // alleen laden als het nodig is
			// na het laden vraagt de navigatie-pagina zelf de in dit script globaal opgeslagen variabele op voor de juiste button-highlight
		} else {
			// wanneer de juiste navigatie al geladen is, direct de button-highlight uitvoeren
			bottomFrame.leftFrame.updateButton(thePage, "A");
		}
	}
}
