![Antiguo](http://static.forosdelweb.com/fdwtheme/images/statusicon/post_old.gif)
21/06/2011, 18:17
|
| | Fecha de Ingreso: septiembre-2009
Mensajes: 138
Antigüedad: 15 años, 5 meses Puntos: 3 | |
Buscar en Php Como buscar en php .
Intente con el siguiente Codigo:
<?php
$selbus="select * from usuario where Nombre='".$_POST['nombrebus']."'";
$ejeselbus=mysql_query($selbus);
echo "<table id=tabla width=500 border=1 align=center>";
echo "<tr id=celdas name=celdas align=center width=350>";
echo "<td width=250 name=id>Nombre</td>";
echo "<td width=250>Apellido</td>";
echo "<td width=250 name=id>Direccion</td>";
echo "<td width=250>Edad</td>";
echo "<td width=250 name=id>Dni</td>";
echo "<td width=250>Correo</td>";
echo "</tr></table>";
while($ins=mysql_fetch_array($ejeselbus))
{
echo "<table id=tabla width=500 border=1 align=center>";
echo "<tr id=celdas name=celdas align=center width=350 onmouseover=this.style.cursor='hand'>";
echo "<td width=250 name=id>";
echo $ins[0];
echo "</td>";
echo "<td width=250 name=id>";
echo $ins[1];
echo "</td>";
echo "<td width=250 name=id>";
echo $ins[2];
echo "</td>";
echo "<td width=250 name=id>";
echo $ins[3];
echo "</td>";
echo "<td width=250 name=id>";
echo $ins[4];
echo "</td>";
echo "<td width=250 name=id>";
echo $ins[5];
echo "</td>";
echo "</tr>";
echo "</table>";
}
?>
Donde nombrebus es el nombre que se pone para buscar. |