function doHideDiv(layerName) {
	f = "hideDiv('" + layerName + "')";
	setTimeout(f, 500);
}

function getLayer(sLayerName) {
  var oLayer = null;
  if (document.all) { // IE
    oLayer = document.all[sLayerName].style;
  } else if (document.layers) { // NS4
    oLayer = document.layers[sLayerName];
  } else if (document.getElementById) { // NS6
    oLayer = document.getElementById(sLayerName).style;
  }
  return oLayer;;
}


function showDiv(sLayerName) {
  var oLayer = null;
  if (document.all) { // IE
    oLayer = document.all[sLayerName].style;
  } else if (document.layers) { // NS4
    oLayer = document.layers[sLayerName];
  } else if (document.getElementById) { // NS6
    oLayer = document.getElementById(sLayerName).style;
  }
  oLayer.visibility = 'visible';
}

function hideDiv(sLayerName) {
  var oLayer = null;
  if (document.all) { // IE
    oLayer = document.all[sLayerName].style;
  } else if (document.layers) { // NS4
    oLayer = document.layers[sLayerName];
  } else if (document.getElementById) { // NS6
    oLayer = document.getElementById(sLayerName).style;
  }
  oLayer.visibility = 'hidden';
}


function blockDiv(sLayerName) {
  var oLayer = null;
  if (document.all) { // IE
    oLayer = document.all[sLayerName].style;
  } else if (document.layers) { // NS4
    oLayer = document.layers[sLayerName];
  } else if (document.getElementById) { // NS6
    oLayer = document.getElementById(sLayerName).style;
  }
  oLayer.visibility = 'visible';
  oLayer.display = 'block';
}

function noneDiv(sLayerName) {
  var oLayer = null;
  if (document.all) { // IE
    oLayer = document.all[sLayerName].style;
  } else if (document.layers) { // NS4
    oLayer = document.layers[sLayerName];
  } else if (document.getElementById) { // NS6
    oLayer = document.getElementById(sLayerName).style;
  }
  oLayer.visibility = 'hidden';
  oLayer.display = 'none';
}


actieveDiv = null;
function showUitleg(divNaam) {
	if (actieveDiv != null ) {
		noneDiv(actieveDiv);
	}
	if (actieveDiv != divNaam)	{
		blockDiv(divNaam);
	}
	actieveDiv = divNaam;
}

function rand(a,b) {
	num = Math.random();
	num = (num*(b-a))+a;
	num = Math.round(num);
	return num;
}

function showSwfAlert(nr) {
	showDiv("divSwfAlert" + nr);
}
