You are here

public function UploadedFileInterface::getClientMediaType in Lockr 7.3

Retrieve the media type sent by the client.

Do not trust the value returned by this method. A client could send a malicious media type with the intention to corrupt or hack your application.

Implementations SHOULD return the value stored in the "type" key of the file in the $_FILES array.

Return value

string|null The media type sent by the client or null if none was provided.

1 method overrides UploadedFileInterface::getClientMediaType()
UploadedFile::getClientMediaType in vendor/guzzlehttp/psr7/src/UploadedFile.php
Retrieve the media type sent by the client.

File

vendor/psr/http-message/src/UploadedFileInterface.php, line 122

Class

UploadedFileInterface
Value object representing a file uploaded through an HTTP request.

Namespace

Psr\Http\Message

Code

public function getClientMediaType();