<?php
session_start();
if (!isset($_SESSION["user_id"]) || $_SESSION["user_id"]==null):
   print "<script>alert(\"Acceso Invalido!\");
   window.location='login.php';</script>";
endif;
if ($_SESSION["user_at"] < 4):
   print "<script>alert(\"Sin Acceso a Transaccion!\");
   window.location='vt000.php';</script>";
endif;
include_once ("lib/fpdf/funci.php");
date_default_timezone_set('America/La_Paz');
$conex = conectar();
?>
<body bgcolor="#E0FFFF">
<div class="main-wrapper">
<link href="css/ttigo.css" rel="stylesheet" type="text/css" />
<link href="bootstrap/css/bootstrap.css" rel="stylesheet" />
<center><h1>Consulta de Grupos</h1></center>
<center><a class="btn btn-success" href="vt243.php">Nuevo</a>
&emsp;&emsp;&emsp;&emsp;&emsp;&emsp;&emsp;&emsp;&emsp;&emsp;
&emsp;&emsp;&emsp;&emsp;&emsp;&emsp;&emsp;&emsp;&nbsp;
&emsp;&emsp;&emsp;&emsp;&emsp;&emsp;&emsp;&ensp;&nbsp;
<a class="btn btn-danger" href="vt000.php">Salir</a></center>
<center><table border="0" cellpadding="0" cellspacing="0" class="tabla">
   <thead>
	<th><center>Item</center></th>
	<th>Grupo</th>
	<th><center>Seleccion</center></th>
   </thead>
<?php
$mysql = "select * from ingrp
          order  by 1 desc";
$result = mysql_query($mysql);
while ($row = mysql_fetch_array($result)): ?>
   <tr class="modo1">
   <td><center><?php echo $row[0];?></center></td>
   <td><?php echo $row[1];?></td>
   <td><center><a class="btn btn-primary btn-xs" href="vt242.php?id=<?php echo $row[0];?>">Modificar</a></center></td>
   </tr>
   <?php
endwhile; ?>
</table></center>
</div>
</body>
