Ver Mensaje Individual
  #3 (permalink)  
Antiguo 12/02/2009, 07:22
snakepit
 
Fecha de Ingreso: diciembre-2001
Ubicación: Argentina
Mensajes: 693
Antigüedad: 23 años, 2 meses
Puntos: 1
Respuesta: Ayuda con tutorial. No me devuelve valores de la BD

Perdon, el codigo php es el siguiente

Código PHP:
<html>
<head>
<title>Reporte de Ciudades</title>
</head>
<body>
<h1>Reporte de Ciudadess</h1>
<table border=”1”>
<tr>
<td>ID Ciudad</td>
<td>Nombre</td>
</tr>

<?php
$conexion 
mysql_connect('localhost''root''');
mysql_select_db('inmobiliaria');
$tabla mysql_query('SELECT * FROM ciudades');
while (
$registro mysql_fetch_array($tabla)) {
?>

<tr>
<td><?php echo $registro[‘id’]; ?></td>
<td><?php echo $registro[‘nombre’]; ?></td>
</tr>

<?php
}
mysql_free_result($tabla);
mysql_close($conexion);
?>

</table>
</body>
</html>