Ver Mensaje Individual
  #4 (permalink)  
Antiguo 17/01/2012, 15:26
Avatar de lobo_php
lobo_php
 
Fecha de Ingreso: noviembre-2007
Ubicación: Cali-Colombia
Mensajes: 1.869
Antigüedad: 16 años, 5 meses
Puntos: 75
Respuesta: Problema con Menu Dinamico PHP y Mysql Hijo

MALO, debe ser así:

Código PHP:
Ver original
  1. if($cant == 0){
  2.   // $menu .= "<li><a href=\"#\">".$row_parent['menu']."</a></li>";
  3.    }else{
  4.        
  5.    $menu .= "<li><a class=\"MenuBarItemSubmenu\" href=\"#\">".$row_parent['menu']."</a><ul>";
  6.    
  7.       while($row_child = mysql_fetch_array($exe2)){
  8.       $menu .="<li><a  href=\"#\">".$row_child['sub_menu']."</a></li>";
  9.      
  10.       }
  11.  //fuera del while y dentro del else
  12. $menu.="</ul>";    
  13.    $menu .="</li>";
  14.  
  15.    }
  16.  
  17.  
  18.  
  19.  
  20.  
  21. }
  22.  
  23.  
  24. echo $menu;
__________________
Cabuntu.org - Difundiendo Software Libre en Cali, Colombia
Usuario Linux # 483175