/**
  * Create archive using php function and return the path
  *
  * @param  string  $dir    target dir
  * @param  array   $files  files names list
  * @param  string  $name   archive name
  * @param  array   $arc    archiver options
  * @return string|bool
  */
 protected function PhpCompress($dir, $files, $name, $archiver)
 {
     include 'Archive.php';
     $path = $this->_joinPath($dir, $name);
     $archive = new Archive($path);
     //add files
     foreach ($files as $file) {
         $add_path = $this->_joinPath($dir, $file);
         $archive->Add($add_path, $file);
     }
     $archive->compress();
     return $path;
 }