Mime-class function

Class Mime and object Mime

Class Mime and object Mime

A convenience object for determining the MIME type of a file name. 1.1

class

Examples

Mime$file_extname('foo.png') Mime$mime_type('.png')

Methods

  • file_extname(fname=NULL):: Returns the file extensions for the given file.
  • mime_type(ext=NULL, fallback='application/octet-stream'):: Returns the MIME type given the file extension. Be sure to include the dot character in ext. If no match is found, then the fallback MIME type is returned.
  • Maintainer: Evan Biederstedt
  • License: GPL-2
  • Last published: 2022-11-07