Está en la página 1de 3

<title>conectar</title><?

php
$u="root";
$p="";
$s="127.0.0.1";
$con=mysql_connect($s,$u,$p);
mysql_select_db("controldedocumentos",$con);
------------------------------------------------------------------------------------<form name="form1" method="post" action="busqueda.php" id="cdr" >
BUSCAR POR DAP
<p>
<input name="busca" type="text" id="datos">
<input type="submit" name="Submit" value="buscar" />
</p>
</p>
</form>
<p>
<style type="text/css">
#tab{background:#CCC;;border-radius:10px 10px 10px 10px;}
</style>
<center>

<?php
require("conectar.php");
if (isset($_POST['busca'])) {
$busca = $_POST['busca'];
} else {

$busca = "";
}
$datos=mysql_query("SELECT * FROM recepcion WHERE folio_doc LIKE
'%".$busca."%'");//cambiar nombre de la tabla de busqueda
?>
<table width="1166" border="1" id="tab">
<tr>
<td width="19">DAP </td>
<td width="157">REFERENCIA</td>
<td width="221">FECHA DE RECEPCION</td>
<td width="176">FECHA DEL DOCUMENTO</td>
<td width="61">REMITENTE</td>
<td width="61">CARGO</td>
<td width="61">DEPENDENCIA</td>
<td width="61">TIPO DE DOCUMENTO</td>
<td width="61">DOCUMENTO</td>
<td width="61">ANEXO</td>
<td width="61">TIPO DE ANEXO</td>
<td width="61">ASUNTO</td>
<td width="61">CAPTURISTA</td>
<td width="61">OBSERVACIONES</td>
</tr>
<?php
while($renglon=mysql_fetch_array($datos)){
echo '<tr>';
echo '<td width="60">'.$renglon['folio_doc'].'</td>';

echo '<td width="60">'.$renglon['referencia'].'</td>';


echo '<td width="60">'.$renglon['fecha_regis'].'</td>';
echo '<td width="60">'.$renglon['fecha_doc'].'</td>';
echo '<td width="60">'.$renglon['folio_remitente'].'</td>';
echo '<td width="60">'.$renglon['cargo'].'</td>';
echo '<td width="60">'.$renglon['dependencia'].'</td>';
echo '<td width="60">'.$renglon['tipo_doc'].'</td>';
echo '<td width="60">'.$renglon['documento'].'</td>';
echo '<td width="60">'.$renglon['folio_anexo'].'</td>';
echo '<td width="60">'.$renglon['tipo_anexo'].'</td>';
echo '<td width="60">'.$renglon['asunto'].'</td>';
echo '<td width="60">'.$renglon['capturista'].'</td>';
echo '<td width="60">'.$renglon['observaciones'].'</td>';
echo"</tr>";
}
?>

También podría gustarte