<?php
 
session_start();
$com = "C";
include("DMMYSQLG.php");
include("DSA3000.php");
include("DMMYSQLG.php");
include("DF30000.inc");
?>
<html>
<link rel="stylesheet" href="css/estilo1.css" type="text/css"/>
<script type="text/javascript" language="JavaScript1.2" src="DSSCRIPT.js"></script>
<?php

if ($_POST['bot']==""){
	echo '<h2>!!! SELECCIONA UN REGISTRO... ACTUALIZANDO !!!</h2>';
	echo '<meta content="1; url=DN21000_PR3.php"  HTTP-EQUIV="REFRESH">';
}else{
	include('DN21000_CL3.php');
	$varible_clase = new clase();
	$res=$varible_clase->lista_busqueda($_POST["bot"]);
	$row=mysqli_fetch_array($res);
?>
<body
<?php
 
if(isset($_POST['bot3'])){
	echo ' onLoad="deshab()"';
}
?>
>
<form  name="frm1" method="post" action="">
<input name="bot" type="hidden" value="<?php
 echo $_POST["bot"]?>">
<table width="400"  align="center">
    <tr>
      <th colspan="4" class=\"titulo\"><div align="center">ESCOLARIDAD</div></th>
    </tr>
	  <tr>
      <td width="80">Nivel Escolar </td>
      <td width="304"> 
        <select name="s1" id="s1" disabled="disabled">
		<?php

			if($row['niv_esc']=="1"){
			  echo '<option value="1" selected>Primaria</option>';
			}else{
			  echo '<option value="1">Primaria</option>';
			}
			if($row['niv_esc']=="2"){
			  echo '<option value="2" selected>Secundaria</option>';
			}else{
			  echo '<option value="2">Secundaria</option>';
			}
			if($row['niv_esc']=="3"){
			  echo '<option value="3" selected>Preparatoria</option>';
			}else{
			  echo '<option value="3">Preparatoria</option>';
			}
			if($row['niv_esc']=="4"){
			  echo '<option value="4" selected>Universidad</option>';
			}else{
			  echo '<option value="4">Universidad</option>';
			}
			if($row['niv_esc']=="5"){
			  echo '<option value="5" selected>Comercial / Otro</option>';
			}else{
			  echo '<option value="5">Comercial / Otro</option>';
			}
		?>
        </select>
      </td>
	  </tr>
	  <tr>
        <td width="80">Nombre </td>
        <td width="304"> 
        <input name="t1" type="text" id="t1" size="45"
		<?php
 
		echo 'value="'.$row['nom'].'"';
		?>
		>
        </td>
    </tr>
    <tr>
      <td width="80">Domicilio</td>
      <td width="304"> 
      <input name="t2" type="text" id="t2" size="45"
		<?php
 
		echo 'value="'.$row['dom'].'"';
		?>
		>
      </td>
    </tr>
	  <tr>
        <td width="80">Fecha Inicial </td>
        <td width="304"> <input name="t3" type="text" class="emplea" id="t3" size="15" readonly
			<?php

			$fec1=$row["fec_ini"];
			include('DF20000.php');
			echo 'value="'.$f_f.'"';
			?>/>
        <input name="reset" id="bot_a" type="image" src="logos/cal4.jpg"/>
        <script type="text/javascript">
  Calendar.setup(
    {
      inputField  : "t3",        // ID of the input field
      ifFormat    : "%d/%m/%Y",    // the date format
      button      : "bot_a"      // ID of the button
    }
  );
</script></td>
    </tr>
	  <tr>
        <td width="80">Fecha Final </td>
        <td width="304"> <input name="t4" type="text" class="emplea" id="t4" size="15" readonly
			<?php

			$fec1=$row["fec_fin"];
			include('DF20000.php');
			echo 'value="'.$f_f.'"';
			?>/>
        <input name="reset" id="bot_b" type="image" src="logos/cal4.jpg"/>
        <script type="text/javascript">
  Calendar.setup(
    {
      inputField  : "t4",        // ID of the input field
      ifFormat    : "%d/%m/%Y",    // the date format
      button      : "bot_b"      // ID of the button
    }
  );
</script></td>
    </tr>
    <tr>
      <td width="80">A&ntilde;os</td>
      <td width="304"> 
      <input name="t5" type="text" id="t5" size="3" onKeyPress="return validar(event)" maxlength="2"
		<?php
 
		echo 'value="'.$row['axos'].'"';
		?>
		>
      </td>
    </tr>
    <tr>
      <td width="80">Documento</td>
      <td width="304"> 
      <input name="t6" type="text" id="t6" size="45"
		<?php
 
		echo 'value="'.$row['doc'].'"';
		?>

		>
      </td>
    </tr>
</table>
<table width="400"  align="center">
    <tr>
      <td colspan="2"><div align="center">
		  <input type="button" name="Submit2" value="Modificar" onClick="openpage('DN21000_MC3.php','_self')"/>
          &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<input type="button" name="Submit2" value="Regresar" onClick="openpage('DN21000_PR3.php','_self')"/>
      </div></td>
    </tr>
  </table>
</form>
     <?php
 
if(isset($_POST['bot3'])){
	echo '<div align="center">
	<form id="form1" name="form1" action="DN21000_PR3.php" target="_self">
		<input type="submit" name="submit" value="Regresar">
	</form>
	</div>';
	
}
?>
 </body>
<?php
 
mysqli_close($con);
}
?>
</html>
