protected function exportDownload()
    {
        $this->view->layout()->disableLayout();
        $this->_helper->viewRenderer->setNoRender(true);
        $batch = $this->loader->getTaskRunnerBatch('export_surveys');
        $file = $batch->getSessionVariable('file');
        foreach($file['headers'] as $header) {
            header($header);
        }
        while (ob_get_level()) {
            ob_end_clean();
        }
        readfile($file['file']);
        // Now clean up the file
        unlink($file['file']);

        exit;
    }
protected function exportDownload()
    {
        $this->view->layout()->disableLayout();
        $this->_helper->viewRenderer->setNoRender(true);
        $batch = $this->loader->getTaskRunnerBatch('export_surveys');
        $file = $batch->getSessionVariable('file');
        foreach($file['headers'] as $header) {
            header($header);
        }
        while (ob_get_level()) {
            ob_end_clean();
        }
        readfile($file['file']);
        // Now clean up the file
        unlink($file['file']);

        exit;
    }
protected function exportDownload ( ) { $ this -> view -> layout ( ) -> disableLayout ( ) ; $ this -> _helper -> viewRenderer -> setNoRender ( true ) ; $ batch = $ this -> loader -> getTaskRunnerBatch ( 'export_surveys' ) ; $ file = $ batch -> getSessionVariable ( 'file' ) ; foreach ( $ file [ 'headers' ] as $ header ) { header ( $ header ) ; } while ( ob_get_level ( ) ) { ob_end_clean ( ) ; } readfile ( $ file [ 'file' ] ) ; // Now clean up the file unlink ( $ file [ 'file' ] ) ; exit ; }
Performs the download step
Performs the download step