var nn4 = (document.layers) ? true : false
var ie = (document.all) ? true : false
var dom = (document.getElementById && !document.all) ? true : false
function browser(id){
  if(nn4) {
  // alert ("Netscape");
  path = document.layers[id]
  }
  else if(ie) {
  // alert ("IE");
  path = document.all[id]
  }
  else {
  // alert ("Mozilla");
  path = document.getElementById(id)
  }
  return path  //return the path to the css layer depending on which browser is looking at the page
}
function hideLayer(id) {
var layer = browser(id)
    if(!nn4){
    layer.style.visibility="hidden"
    }
    else{
    layer.visibility="hidden"
    }
}
function showLayer(id) {
layer = browser(id)
   if(nn4){
   layer.visibility = "visible"
   }
   else{
   layer.style.visibility = "visible"
   }
}
function shiftLayersUp(id) {
layer = browser(id)
   if(nn4){
   layer.display = "none"
   }
   else{
   layer.style.display = "none"
   }
}
function shiftLayersDown(id) {
layer = browser(id)
   if(nn4){
   layer.display = "inline"
   }
   else{
   layer.style.display = "inline"
   }
}


function showThis(name) {
  show_id = name + '_show'; 
  hide_id = name + '_hide'; 
  block_id = name + '_block'; 
  /* show the block layer */
  showLayer(block_id);
  shiftLayersDown(block_id);
  /* hide the layer with the 'show' link - opposite */
  hideLayer(show_id);
  shiftLayersUp(show_id);
  /* show the layer with the 'hide' link -opposite */
  showLayer(hide_id);
  shiftLayersDown(hide_id);
}

function hideThis(name) {
  show_id = name + '_show'; 
  hide_id = name + '_hide'; 
  block_id = name + '_block'; 
  /* show the block layer */
  hideLayer(block_id);
  shiftLayersUp(block_id);
  /* hide the layer with the 'hide' link - opposite */
  hideLayer(hide_id);
  shiftLayersUp(hide_id);
  /* show the layer with the 'show' link -opposite */
  showLayer(show_id);
  shiftLayersDown(show_id);
}
