// change this to your include path
// The three methods in this extended class override the base class methods which don't do much.
// That's basically how you use folderbot. You get the stuff which doesn't do much in the base class to work for you
class listfolder extends folderbot
// uncomment below to filter
// Triggered by the parent class, it is called every time a file matching the filter has been found
// in this example, it prints the file which is stored in a class variable called curfile.
// Called every time a folder is found. It just prints its name
//here we go
$bot->set_recurse(true); // set to false to only list the folder without subfolder.
$bot->scan("./"); // will scan wherever you have placed the example. make sure you have access permission there and below :)