Skip to content

UploadedFile: getError Example

Terry L edited this page Jun 20, 2020 · 2 revisions

Shieldon\Psr7\UploadedFile

getError()

Retrieve the error associated with the uploaded file.

  • return int

Example:

$uploadedFile = new \Shieldon\Psr7\UploadedFile(
    '/tmp/php200A.tmp',
    'example1.jpg',
    'image/jpeg',
    100000,
    0
);

$uploadedFile->getError();
// Outputs: 0
Clone this wiki locally