<?php
include('conexion_oracle.php');
$busqueda = $_POST["buscar"];
if($busqueda !=""){
$sql="SELECT * FROM programador WHERE nombre LIKE '%$busqueda%' ORDER BY nombre ASC";
$sentencia=OCIParse($conexion,$sql);
OCIDefineByName($sentencia,"DNI",$dni_prog);
OCIDefineByName($sentencia,"NOMBRE",$nom_prog);
OCIExecute($sentencia);
}
?>
<html>
<head>
<title>CONSULTAR DATOS</title>
</head>
<body>
<h3>BUSCADOR DE PROGRAMADORES</h3>
<form action="BUSQUEDA1.PHP" method="post">
<input type="text" name="buscar"/>
<input type="button" name="boton" value="BUSCAR" />
</form>
<table>
<tr>
<th>DNI</th>
<th>NOMBRE</th>
</tr>
<?php while(OCIFetch($sentencia)){?>
<tr>
<td><?php echo $dni_prog; ?> </td>
<td><?php echo $nom_prog; ?> </td>
</tr>
</table>
<?php } ?>
</body>
</html>