library/Extlib/FileManager.php
static public function removeFiles($directory)
    {
        $scan = glob(rtrim($directory, '/') . '/*');
        foreach ($scan as $file) {
            if (is_file($file)) {
                unlink($file);
            }
        }

        return true;
    }
static public function removeFiles($directory)
    {
        $scan = glob(rtrim($directory, '/') . '/*');
        foreach ($scan as $file) {
            if (is_file($file)) {
                unlink($file);
            }
        }

        return true;
    }
Remove all files from directory

@param string $directory
@return boolean