Simple function that will return the MIME type from a file extension or extension from MIME type. Includes Scan URL mode.
Please feel free to get in touch if you need a file type added.
Drop the element on your page and use the “Get MIME/Extension” element action. The custom state “Output” will have the result.
Eg. provide “image/png” -> receive “.png”
provide “png” -> receive “image/png”
https://something.somewhere.com/file/myfile.gif” -> receive “image/gif”
Note, Providing a MIME type will return a full stop with the extension for convenience.
If no match is found it will default to MIME type “application/octet-stream”. or “.unknown”
Get it HERE.