Ver Mensaje Individual
  #1 (permalink)  
Antiguo 19/04/2007, 20:49
Avatar de AJVEvoluzione
AJVEvoluzione
 
Fecha de Ingreso: agosto-2004
Ubicación: Buenos Aires
Mensajes: 195
Antigüedad: 19 años, 8 meses
Puntos: 1
Como obtener una lista de una BD con PHP?

Mi consulta es porque soy nuevo en el tema de base de datos, cree una y quiero obtener un listado de la misma, pero no me funciona, me aparece en blanco, alguien sabe por que será? dejo el codigo para que me den una idea

Código PHP:
<html> 
<head> 
<title>Reporte de Ciudades</title> 
</head> 
<body> 
<h1>Reporte de Ciudades</h1> 
<table> 
<tr> 
<td>ID Ciudad</td> 
<td>Nombre</td> 
</tr>  
<?php 
$dbh 
= @mysql_connect('localhost''buenosa_32''1234tt'); 
@
mysql_select_db('buenosa_busca8'); 
$tabla = @mysql_query('SELECT * FROM propiedades'); 
while (
$_registro = @mysql_fetch_array($tabla));{ 
?> 
<tr> 
<td><?php echo $_registro['ref']; ?></td>   
<td><?php echo $_registro['nombre']; ?></td>  
</tr> 
<?php 

@
mysql_free_result($tabla); 
@
mysql_close($dbh); 
?> 
</table> 
</body> 
</html>