<?
/*Sesiones*/
include("../conex.php");

$txt_rut='76.572.624-7';
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<title>Busca Boleta</title>
<style type="text/css">
<!--
body {
	background-color: #efefef;
	margin-left: 0px;
	margin-top: 3px;
	margin-right: 0px;
	margin-bottom: 0px;
}
.Estilo7 {
	font-size: small;
	color: #000099;
}
.Estilo11 {font-family: Verdana, Arial, Helvetica, sans-serif; font-size: small; color: #000099; }
.Estilo13 {
	font-family: Verdana, Arial, Helvetica, sans-serif;
	font-size: 9px;
	color: #000099;
	text-decoration: underline;
}
.Estilo14 {
	font-family: Verdana, Arial, Helvetica, sans-serif;
	font-size: 9px;
	color: #000099;
}
.titulos2 {
	font-family: Verdana, Arial, Helvetica, sans-serif;
	font-size: 13px;
	color: #003366;
	
	font-style: normal;
	font-weight: bold;
}
.botones {
	font-family: Verdana, Arial, Helvetica, sans-serif;
	font-size: 12px;
	font-weight: bold;
	height:26px;
}
-->
</style>

</head>
<script language="JavaScript" src="../css/cal.js" type="text/JavaScript"></script>
<table width="90%" border="0" align="center">
	<tr>
		<td><div align="center" class="titulos2">
		Busqueda de Boleta Electronica
		</div></td>
	</tr>
</table>
<body vlink="#2293ff" alink="#2293ff" link="#2293ff">
<form name="form1" method="post" action="busca_bol.php">
<div align="left" class="titulos2" style="font-size:12px">
  <table width="35%" border="1" align="center">
    <tr>
      <td>Folio Boleta </td>
      <td>
        <table width="100%" border="0" cellpadding="0" cellspacing="0">
          <tr>
           <td><input name="txtfolio" type="text" id="txtfolio" value="<?=$txt_folio?>" size="40" /></td>
           </tr>
        </table></td>
    </tr>
	 <tr>
      <td>RUT Emisor</td>
      <td>
        <table width="100%" border="0" cellpadding="0" cellspacing="0">
          <tr>
            <td><input name="txtrut" type="text" id="txtrut" size="40" value="<?=$txt_rut?>" onblur="comprueba()"  onKeyPress="return valida(event)"></td>
            </tr>
        </table></td>
    </tr>
  
	       
          
    <table width="90%" border="0" align="center" cellpadding="0" cellspacing="0">
    <tr>
      <td>&nbsp;</td>
      <td><div align="center">
        <label>
        <input type="button" name="Submit" value="Buscar" onClick="enviar();">
        </label>
      </div></td>
      <td>&nbsp;</td>
    </tr>
  </table>
 
</form>

<script type="text/javascript" src="../css/validarut.js"></script>
<script type="text/javascript" src="../css/validarut2.js"></script>
<script language="javascript">
var nav4 = window.Event ? true : false;
<!-- Ingreso solo letras -->
function valida(evt){
var key = nav4 ? evt.which : evt.keyCode;
	if (key==13) document.form1.txtrsoc.focus()
	return (key <= 13 || (key >= 48 && key <= 57) || (key == 107) || (key == 75) || (key == 45) || (key == 46));
	}



function comprueba()
	{
	if (Rut(document.form1.txtrut.value)) document.form1.txtfecha.focus();
	}
function comprueba2()
	{
	if (Rut2(document.form1.txtrut_empresa.value)) document.form1.txtnombre.focus();
	}	  
function enviar()
	{
	if (document.form1.txtfolio.value=='')
		{
		alert('Ingrese Folio de Boleta');
		document.form1.txtfolio.focus();
		return false;
		}
	if (document.form1.txtrut.value=='')
		{
		alert('Ingrese Rut Emisor');
		document.form1.txtrut.focus();
		return false;
		}
	
	document.form1.submit();
	}

</script>