示例#1
0
 public function pull($file)
 {
     $folders = explode("/", $file);
     array_pop($folders);
     $base = Kohana::config('myshot.basePath') . implode("/", $folders);
     !file_exists($base) ? mkdir($base, 0777, true) : null;
     parent::download(Kohana::config('myshot.basePath') . $file, "/{$this->rootDir}/" . $file);
     return $this;
 }