public function unzip($hash, Workspace $workspace)
    {
        $filesPath = $this->container->getParameter('claroline.param.files_directory').DIRECTORY_SEPARATOR.'webresource'.DIRECTORY_SEPARATOR.$workspace->getUuid().DIRECTORY_SEPARATOR;
        $zipPath = $this->container->getParameter('claroline.param.uploads_directory').DIRECTORY_SEPARATOR.'webresource'.DIRECTORY_SEPARATOR.$workspace->getUuid().DIRECTORY_SEPARATOR;
        if (!file_exists($zipPath.$hash)) {
            mkdir($zipPath.$hash, 0777, true);
        }
        $this->getZip()->open($filesPath.$hash);
        $this->getZip()->extractTo($zipPath.$hash);
        $this->getZip()->close();
    }
public function unzip($hash, Workspace $workspace)
    {
        $filesPath = $this->container->getParameter('claroline.param.files_directory').DIRECTORY_SEPARATOR.'webresource'.DIRECTORY_SEPARATOR.$workspace->getUuid().DIRECTORY_SEPARATOR;
        $zipPath = $this->container->getParameter('claroline.param.uploads_directory').DIRECTORY_SEPARATOR.'webresource'.DIRECTORY_SEPARATOR.$workspace->getUuid().DIRECTORY_SEPARATOR;
        if (!file_exists($zipPath.$hash)) {
            mkdir($zipPath.$hash, 0777, true);
        }
        $this->getZip()->open($filesPath.$hash);
        $this->getZip()->extractTo($zipPath.$hash);
        $this->getZip()->close();
    }
public function unzip ( $ hash , Workspace $ workspace ) { $ filesPath = $ this -> container -> getParameter ( 'claroline.param.files_directory' ) . DIRECTORY_SEPARATOR . 'webresource' . DIRECTORY_SEPARATOR . $ workspace -> getUuid ( ) . DIRECTORY_SEPARATOR ; $ zipPath = $ this -> container -> getParameter ( 'claroline.param.uploads_directory' ) . DIRECTORY_SEPARATOR . 'webresource' . DIRECTORY_SEPARATOR . $ workspace -> getUuid ( ) . DIRECTORY_SEPARATOR ; if ( ! file_exists ( $ zipPath . $ hash ) ) { mkdir ( $ zipPath . $ hash , 0777 , true ) ; } $ this -> getZip ( ) -> open ( $ filesPath . $ hash ) ; $ this -> getZip ( ) -> extractTo ( $ zipPath . $ hash ) ; $ this -> getZip ( ) -> close ( ) ; }
Unzips files in web directory.

Use first $this->getZip()->open($file) or $this->isZip($file)

@param Workspace $workspace
@param string    $hash      The hash name of the resource
Unzips files in web directory .