FOSSology  4.5.1
Open Source License Compliance by Open Source Software
Fossology\Lib\Util\DownloadUtil Class Reference
Collaboration diagram for Fossology\Lib\Util\DownloadUtil:
Collaboration graph

Static Public Member Functions

static getDownloadConfirmationResponse ($downloadUrl, $fileName, $referer)
 
static getDownloadResponse ($content, $fileName, $contentType='text/csv')
 

Detailed Description

Definition at line 11 of file DownloadUtil.php.

Member Function Documentation

◆ getDownloadConfirmationResponse()

static Fossology\Lib\Util\DownloadUtil::getDownloadConfirmationResponse (   $downloadUrl,
  $fileName,
  $referer 
)
static

Creates a response with download confirmation

Parameters
string$downloadUrlThe URL to download from
string$fileNameThe name of the file to be downloaded
string$refererThe page to redirect to after download
Returns
Response

Definition at line 20 of file DownloadUtil.php.

◆ getDownloadResponse()

static Fossology\Lib\Util\DownloadUtil::getDownloadResponse (   $content,
  $fileName,
  $contentType = 'text/csv' 
)
static

Creates a response for file download

Parameters
string$contentThe file content
string$fileNameThe name of the file
string$contentTypeThe content type of the file
Returns
Response

Definition at line 56 of file DownloadUtil.php.


The documentation for this class was generated from the following file: