     /*************************************************************************
      *                                                                       *
      *  Conjunto de funciones JavaScript usadas en la interfaz web de Sisalud*
      *                                                                       *
      *************************************************************************/

  var browserOK = false;
  var ioff;
  var ion;

  browserOK = true;
  ioff = new Image();
  ioff.src="/archstma/off.gif";
  ion= new Image();
  ion.src="/archstma/on.gif";

 
  // Seteo previo de variables
  var left = 168;
  var top = 140;
  var divRef = "";
  var styleSwitch = "";
  if (navigator.appName == "Netscape")
  { divRef = "document.layers";
    styleSwitch = "";
  }
  else
  { divRef = "document.all";
    styleSwitch = ".style";
  }

  // Función que muestra un código HTML oculto
  function showDiv (divName)
  { switch ( divName )
    { case 'ventajas':
      { eval ( divRef + '["' + divName + '"]' + styleSwitch + '.left =' +250);
        eval ( divRef + '["' + divName + '"]' + styleSwitch + '.top =' + 110);
        eval ( divRef + '["' + divName + '"]' + styleSwitch + '.visibility="visible"');
        break;
      }
      case 'planes':
      { eval ( divRef + '["' + divName + '"]' + styleSwitch + '.left =' + 250);
        eval ( divRef + '["' + divName + '"]' + styleSwitch + '.top =' + 110);
        eval ( divRef + '["' + divName + '"]' + styleSwitch + '.visibility="visible"');
        break;
      }
      case 'central':
      { eval ( divRef + '["' + divName + '"]' + styleSwitch + '.left =' +250);
        eval ( divRef + '["' + divName + '"]' + styleSwitch + '.top =' +110);
        eval ( divRef + '["' + divName + '"]' + styleSwitch + '.visibility="visible"');
        break;
      }
      case 'red':
      { eval ( divRef + '["' + divName + '"]' + styleSwitch + '.left =' + 250);
        eval ( divRef + '["' + divName + '"]' + styleSwitch + '.top =' + 110);
        eval ( divRef + '["' + divName + '"]' + styleSwitch + '.visibility="visible"');
        break;
      }
      case 'farmacia':
      { eval ( divRef + '["' + divName + '"]' + styleSwitch + '.left =' + 250);
        eval ( divRef + '["' + divName + '"]' + styleSwitch + '.top =' + 90);
        eval ( divRef + '["' + divName + '"]' + styleSwitch + '.visibility="visible"');
        break;
      }
      case 'cafe':
      { eval ( divRef + '["' + divName + '"]' + styleSwitch + '.left =' + 250);
        eval ( divRef + '["' + divName + '"]' + styleSwitch + '.top =' + 110);
        eval ( divRef + '["' + divName + '"]' + styleSwitch + '.visibility="visible"');
        break;
      }
    }
  }

  // Función que oculta un código HTML en pantalla
  function hideDiv (divName)
  { eval ( divRef + '["' + divName + '"]' + styleSwitch + '.visibility="hidden"');
  }

  // Cambiar la imagen definida en theElement por newImg
  function changeImg (theElement,newImg)
  { theElement.src = newImg;
  }

 