is there a way to output a folder and its files like this using php
this is my directories
folder/12345/file1.php
folder/46745/file1.php
folder/57756/file1.php
i tried this ...
$a = glob("folder/*");
foreach ($a as $key) {
echo $key."<br>";
}
but the output will be like this
folder/12345
folder/46745
folder/57756
i am trying to make output to be more like ...
folder/12345
file.php
folder/46745
file1.php
folder/57756
file.php
my point is how many file is inside a folder should be outputted below the folder. hope some one help me with this. thanks
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…