I have the following php array:
Array ( [0] => fdsa.txt
[1] => lubuntu-19.10-desktop-amd64.iso
[2] => Solicitacao_de_Liberacao_a_Rede_WIFI.xlsx
[teste\] => Array ( [0] => pasta1.txt [1] => pasta2.txt )
[teste2\] => Array ( [0] => pasta3.txt [1] => pasta4.txt ) )
I want to use foreach
to run through the array and echo everything
foreach($map as $arquivo){
echo $arquivo."<br/>";
}
But i want to show the name of the arrays instead of what is inside them like this:
fdsa.txt
lubuntu-19.10-desktop-amd64.iso
Solicitacao_de_Liberacao_a_Rede_WIFI.xlsx
teste\
teste2\