FileGetMimeType
Gets the MIME type for the file path/file object you have specified.
Method Signature
Arguments
Examples
Related
Last updated
Gets the MIME type for the file path/file object you have specified.
Last updated
Argument | Type | Required | Description | Default |
---|---|---|---|---|
file
string
true
The file path or file object to get the MIME type for.
strict
boolean
false
If true, throws an exception if the file does not exist or is empty. If false, returns "application/octet-stream" for non-existent or empty files.
true