Hi I'm a disciple seeking help from the Masters. I wanted to navigate the folders using PHP here's my code:
foreach (glob ("folderswithsubfoldersandfilesinit") as $path) {
$file = basename($path);
echo '<ul><a href="'.$path.'">'.$file.'</a></ul>';
}
The code above will display the files inside the specified folder. What if some items in it is a subfolder? What code will I add if I want to click the subfolder and see the files in it? I really need help thanks.