Class Download
Download component
Simplifies the file download/stream process by setting the appropriate headers
Package: blesta\components\download
Copyright: Copyright (c) 2010, Phillips Data, Inc.
License: The Blesta License Agreement
Link: Blesta
Located at components/download/download.php
Copyright: Copyright (c) 2010, Phillips Data, Inc.
License: The Blesta License Agreement
Link: Blesta
Located at components/download/download.php
Methods summary
public
|
#
__construct( mixed $encoding = "binary" )
Initializes the Download object, sets the default encoding |
public
|
|
public
|
|
public
|
#
streamFile( string $file, string $file_name = null, string $send_mode = "file" )
Streams a file out to the standard output stream (e.g. a browser) |
public
|
#
streamData( string $file_name, string $data )
Streams the given data to the standard output stream (e.g. a browser) |
public
|
#
downloadFile( string $file, string $file_name = null, string $send_mode = "file" )
Forces download of a file |
public
|
|
private
|
|
private
|
Magic methods summary
Properties summary
private
string
|
$encoding |
#
The encoding used to deliver the file |
private
array
|
$content_type |
#
An array of content types to set when deliverying the file |