I'm not getting the logic, can anyone help me out? With this code:
PHP Code:
echo '<ul class="subCategorias">';
    
        foreach (
$arrMenu as $subcategorias)
    {
       
      echo 
'<li>';
      echo 
anchorbase_url() . 'c_categoria/seccao/' $subcategorias[$strParentIdKey] . '/' $subcategorias[$strIdKey] . '/',$subcategorias[$strNameKey]),$strNL;
      echo 
'</li>';
        
       
       if(!empty(
$subcategorias[$strChildKey])) 
          {
        if (isset(
$arraySegmento[4]) and $arraySegmento[4]==6)
        {
            echo 
'<ul class="subSubCategorias">';
    
              foreach (
$subcategorias[$strChildKey] as $subsubcategorias)
              {
                      
                echo 
'<li>'
                echo 
anchorbase_url() . 'c_categoria/seccao/1/' $subsubcategorias[$strParentIdKey] . '/' $subsubcategorias[$strIdKey] . '/',$subsubcategorias[$strNameKey]),$strNL;
                echo 
'</li>';
              }
                
                echo 
'</ul>';
        }
                   
    }
        
             

I'm able to generate something like this:
HTML Code:
<ul>
 <li>cat-1</li>
 <li>cat-2</li>
 <li>cat-3</li>
 <ul>
  <li>subcat-1</li>
  <li>subcat-2</li>
  <li>subcat-3</li>
 </ul>
</ul>
But I would like to have two UL siblings instead:
HTML Code:
<ul>
 <li>cat-1</li>
 <li>cat-2</li>
 <li>cat-3</li>
</ul>
<ul>
 <li>subcat-1</li>
 <li>subcat-2</li>
 <li>subcat-3</li>
</ul>
So that I can properly place them side by side using css. Can I have your help please?


Regards,
Márcio