Example #1
0
 protected function createCompress($fileName, File $file)
 {
     if ($this->request->getParam('compression') == 'zip') {
         $response = $file->createZip(array($fileName), $this->collection . '.zip', TRUE);
         if ($response) {
             return $this->collection . '.zip';
         } else {
             return false;
         }
     }
 }