buffer = "Starting file dumper of ".$path; $this->path = $path; $this->construct_tree($this->path); } function construct_tree($path) { $this->handle = opendir($this->path) or die("error #1"); $this->buffer .= "
Directory: ".$this->path; while(false !== ($this->file = readdir($this->handle))) { if(!in_array($this->file,$this->not_countable)) { if(is_file($this->file)) { echo($this->file."
"); } elseif(is_dir($this->file)) { # $this->construct_tree($this->file); } } } closedir($this->handle); } } $ins = new file_tree("./"); ?>