Ver Mensaje Individual
  #2 (permalink)  
Antiguo 07/07/2008, 10:56
Avatar de T4ke0veR
T4ke0veR
 
Fecha de Ingreso: agosto-2007
Ubicación: Quito - Ecuador
Mensajes: 1.720
Antigüedad: 16 años, 8 meses
Puntos: 28
Respuesta: no se imprimen los datos

lo hice llamando directamente a $row en la condicion y me sigue dando q no hay registros
Código PHP:
<?php include('conect.php');
$sql="SELECT * from categoria ORDER BY nombre ASC";
$sql_exec=mysql_query($sql) or die( "[ERROR] Query: $sql, error: " mysql_error() );
$total mysql_num_rows($sql_exec);
?> 
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
</head>

<body>
<?php if ($row 0) { ?>
<?php 
while($row=mysql_fetch_assoc($sql_exec)){ ?>
<table width="250" border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td><?php echo $row['$nombre']; ?>&nbsp;</td>
  </tr><?php ?> <?php } else {
      echo (
"No hay categorias para mostrar");
?>
</table>
</body>
</html>
__________________
Diseño gráfico, Web, imagen corporativa, publicidad ...