File::__construct( string $file, string|null $mimeType = null )

In this article

Constructor.

Parameters

$filestringrequired
The file string (URL, base64 data, or local path).
$mimeTypestring|nulloptional
The MIME type of the file (optional).

Default:null

Source

public function __construct(string $file, ?string $mimeType = null)
{
    // Detect and process the file type (will set MIME type if possible)
    $this->detectAndProcessFile($file, $mimeType);
}

Changelog

VersionDescription
0.1.0Introduced.

User Contributed Notes

You must log in before being able to contribute a note or feedback.