mimetype
mime2ext
¶
Converts a MIME type to its corresponding file extension.
Parameters
Name | Type | Description |
---|---|---|
mimetype |
any | The MIME type to convert. |
Returns: The file extension corresponding to the given MIME type.
ext
¶
Extracts the file extension from a given string.
Parameters
Name | Type | Description |
---|---|---|
str |
any | The input string. |
Returns: The file extension.
ext2mime
¶
Converts a file extension to a MIME type.
Parameters
Name | Type | Description |
---|---|---|
ext |
any | The |
Returns: The corresponding MIME type for the given extension.