public function remove() { $path = $_POST['path']; include_once ROOT . DS . 'includes' . DS . 'file.php'; $file = new File(); $this->root = dirname(ROOT); $src = $this->root . DS . $path; $src = str_replace('/', DS, $src); echo $file->removeFolder($src); exit; }