var W3C = document.getElementById? true : false;
var NN4 = document.layers? true : false;
var IE4 = document.all? true : false;

var last = null;
var last_active = null;

function move_in(img_name,img_src) 
{
	document[img_name].src=img_src;
}
function move_out(img_name,img_src)
{
		document[img_name].src=img_src;
}


function show(layerName)
{
	if (W3C)
	{
		document.getElementById(layerName).style.visibility = "visible";
	}
	else if (IE4) 
	{
		document.all[layerName].style.visibility = "visible";
	}
	else if(NN4) 
	{
		document.layers[layerName].visibility = "show";
	}
}

function hide(layerName)
{
	if (W3C)
	{
		document.getElementById(layerName).style.visibility = "hidden";
	}
	else if (IE4) 
	{
		document.all[layerName].style.visibility = "hidden";
	}
	else if(NN4)
	{
		document.layers[layerName].visibility = "hidden";
	}
}

function swapVisibility(layerName,layer2,distance)
{
	if (W3C)
	{
		if (document.getElementById(layerName).style.visibility == "visible")
		{
			hide(layerName);
			moveBack(layer2,distance);
		}
		else
		{
			show(layerName);
			moveForth(layer2);
		};
	}
	else if (IE4) 
	{
		document.all[layerName].style.visibility = "visible";
	}
	else if(NN4) 
	{
		document.layers[layerName].visibility = "show";
	}
}

function swapLayers(layername1,layername2)
{
	if (last != null)
	{
		show(last);
	}
	if (last_active != null)
	{
		hide(last_active);
	}
	show(layername2);
	hide(layername1);
	last = layername1;
	last_active = layername2;
}

function highlight(cell) 
{
	cell.className = "highlight";
}	
function dim(cell) 
{
	cell.className = "framed";
}
function gotoURL(url)
{
	window.location = url;
}
function changeImage(img_name,img_src) 
{
	document[img_name].src=img_src;
}

function openpopup(popurl)
{
	winpops=window.open(popurl,"","width=800,height=640,");
}

function openwindow(popurl)
{
	winpops=window.open(popurl,"","width=500,height=400,");
}

function openvenster(popurl)
{
	winpops=window.open(popurl,"","");
}


