function preloadImage(pathOfImage) 
{
	var theImage = new Image();
	theImage.src   = pathOfImage;
}									
function hlRegio(nr) 
{
this.className=nr +'aover';
	var xMapImage                = xGetElementById('theMapImage');
	var currentImagePath         = ""+ xMapImage.src;
	var positionOfDot            = currentImagePath.lastIndexOf(".");
	var currentImagePathCut      = currentImagePath.substring(0, positionOfDot);	
	var newImagePath             = currentImagePathCut + "_" + nr + ".gif";

	//alert("currentImagePath: "+ currentImagePath);
	//alert("newImagePath: "+ newImagePath);
	
	xMapImage.src                = newImagePath;

}

function highlightTitleRegion(characterOfTitle) 
{
	var xMapImage                = xGetElementById('theMapImage');
	var currentImagePath         = ""+ xMapImage.src;
	var positionOfLastUnderscore = currentImagePath.lastIndexOf("_");
	var currentImagePathCut      = currentImagePath.substring(0, positionOfLastUnderscore+1);	
	var newImagePath             = currentImagePathCut + characterOfTitle + ".gif";
	xMapImage.src                = newImagePath;
}

function showRegio(rg)
{
	this.className=rg +'aout';
	var xMapImage           = xGetElementById('theMapImage');
	var currentImagePath    = ""+ xMapImage.src;
	var positionOfDot       = currentImagePath.lastIndexOf(".");
	var currentImagePathCut = currentImagePath.substring(0, positionOfDot-3);							
	var newImagePath        = currentImagePathCut + ".gif";
	xMapImage.src           = newImagePath;
}


function showInitialTitleImage()
{
	var xMapImage           = xGetElementById('theMapImage');
	var currentImagePath    = ""+ xMapImage.src;
	var positionOfDot       = currentImagePath.lastIndexOf(".");
	var currentImagePathCut = currentImagePath.substring(0, positionOfDot-1);							
	var newImagePath        = currentImagePathCut + ".gif";
	xMapImage.src           = newImagePath;
}
										
