BlueSpice MediaWiki master
 All Classes Namespaces Files Functions Variables Groups Pages
WebRequestUpload Class Reference

Public Member Functions

 __construct ($request, $key)
 
 exists ()
 
 getName ()
 
 getSize ()
 
 getTempName ()
 
 getError ()
 
 isIniSizeOverflow ()
 

Protected Attributes

 $request
 
 $doesExist
 
 $fileInfo
 

Detailed Description

Object to access the $_FILES array

Constructor & Destructor Documentation

WebRequestUpload::__construct (   $request,
  $key 
)

Constructor. Should only be called by WebRequest

Parameters
WebRequest$requestThe associated request
string$keyKey in $_FILES array (name of form field)

Member Function Documentation

WebRequestUpload::exists ( )

Return whether a file with this name was uploaded.

Returns
bool
WebRequestUpload::getError ( )

Return the upload error. See link for explanation https://secure.php.net/manual/en/features.file-upload.errors.php

Returns
int One of the UPLOAD_ constants, 0 if non-existent
WebRequestUpload::getName ( )

Return the original filename of the uploaded file

Returns
string|null Filename or null if non-existent
WebRequestUpload::getSize ( )

Return the file size of the uploaded file

Returns
int File size or zero if non-existent
WebRequestUpload::getTempName ( )

Return the path to the temporary file

Returns
string|null Path or null if non-existent
WebRequestUpload::isIniSizeOverflow ( )

Returns whether this upload failed because of overflow of a maximum set in php.ini

Returns
bool

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