original_string: 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;
      }
code: 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;
      }
code_tokens: 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 ; }
docstring: Performs the download step
docstring_tokens: Performs the download step