Ver Mensaje Individual
  #12 (permalink)  
Antiguo 17/01/2008, 11:56
Avatar de GatorV
GatorV
$this->role('moderador');
 
Fecha de Ingreso: mayo-2006
Ubicación: /home/ams/
Mensajes: 38.567
Antigüedad: 18 años
Puntos: 2135
Re: etiqueta <ul></ul> dentro de bucle while

Mas bien metelos dentro del if:
Código PHP:
foreach ($categorias as $categoria)
{
    if( !empty( 
$categoria[0] ) ) {
           echo 
"<h1>" $categoria[0] . "</h1>";
    }
    if (
count($categoria[1]) > 0)
    {
        echo 
"<ul class='sidemenu'>";
        foreach (
$categoria[1] as $subCat)
        {
            echo 
"<li><a href='index.php?mod=categoria&amp;categoriaID=" $subCat[0] . "'>" .
                
$subCat[1] . "</a></li>";
        }
        echo 
"</ul>";
    }

Saludos.