<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" /> 

<?php  
 //conexion a la base de datos
 include("conexion.php");
 //echo "entra a header";
    
  //verifica la sesion correcta del usuario
  session_start();    
  $acceso = $_SESSION [ "acceso" ];   
  if ($acceso !=1){    
     header('Location: index.php');
  }
  $s_nitEmpresa = $_SESSION['nitEmpresa']; 
  $s_codSede    = $_SESSION['codSede'];
  $s_usuario    = $_SESSION['nombreUsuario'];
  $s_empresa    = $_SESSION['empresaUsuario'];
  $s_cargo      = $_SESSION['cargoUsuario'];
  $s_idUsuario  = $_SESSION['idUsuario'];
  
  
  //DEFAULT HORA EN BOGOTA;
  date_default_timezone_set("America/Bogota");
  $fecha =  date("Y/m/d H:i:s");

  function cuantosTmp($tabla, $temporal, $historia)
  { 
    $query = " SELECT COUNT(*) as cuantos FROM $tabla WHERE numTemporal = $temporal AND tipoHistoria='$historia' ";
    //echo $query; 
    $result = mysql_query($query) or die('Consulta de cantidad $tabla: ' . mysql_error());
    $line = mysql_fetch_array($result, MYSQL_ASSOC);
    $ct = $line["cuantos"];
    // Liberar resultados
    mysql_free_result($result);
    // Cerrar la conexion
    //mysql_close($link);
    return $ct;  
  }

?>
  
<!DOCTYPE html>
<html lang="en">
 <head>
  <?php  
    //echo "<meta http-equiv='refresh' content='1800; URL=ctlLog.php?usu=$s_idUsuario&mod=DTO'>"; //1800 = 30 MINUTOS DE ESPERA
    echo "<meta http-equiv='refresh' content='5400; URL=ctlLog.php?LDX=$leDX' target='_top'>"; //5400 = 90 MINUTOS DE ESPERA
  ?>
  <meta http-equiv="Content-Type" content="text/html; charset=euc-jp">
  <link rel="stylesheet" href="estilos.css">
  <link rel="stylesheet" href="styles/style.css">
  <link rel="stylesheet" href="fonts/styleFont.css">
  <link rel="stylesheet" href="iconmoon/style.css">
  
  <link rel="icon" type="image/png" href="imagenes/hdIcon.png" /> 
  
  <script src="SpryAssets/SpryTabbedPanels.js" type="text/javascript"></script>
  <script src="SpryAssets/SpryValidationPassword.js" type="text/javascript"></script>
  <script src="SpryAssets/SpryValidationConfirm.js" type="text/javascript"></script>
  <script src="SpryAssets/SpryValidationTextField.js" type="text/javascript"></script>
  <script src="SpryAssets/SpryCollapsiblePanel.js" type="text/javascript"></script>
  
  <link href="SpryAssets/SpryTabbedPanels.css" rel="stylesheet" type="text/css" />
  <link href="SpryAssets/SpryValidationPassword.css" rel="stylesheet" type="text/css" />
  <link href="SpryAssets/SpryValidationConfirm.css" rel="stylesheet" type="text/css" />
  <link href="SpryAssets/SpryValidationTextField.css" rel="stylesheet" type="text/css" />
  <link href="SpryAssets/SpryCollapsiblePanel.css" rel="stylesheet" type="text/css" />
  
  <!--LINEAS PARA FECHA -->
  <link rel="stylesheet" type="text/css" href="../hdCustomer/datetimepicker-master/jquery.datetimepicker.css"/>
  <style type="../hdCustomer/datetimepicker-master/text/css">
   .custom-date-style {
	background-color: red !important;
  }

  .input{	
  }
  .input-wide{
    width: 500px;
  }
 </style>
   
  <title>Health Doc - SIME </title>   
  <script src="js/custom.js"></script> 
  <script src="js/funcHealt.js"></script> 
  <script language=JavaScript>
    function inhabilitar(){
    //alert ("Esta funcion esta inhabilitada.\n\nPerdonen las molestias.")
    return false
    }
    document.oncontextmenu=inhabilitar
  </script> 
  
