public static function detectByFileExtension($extension)
	{
		static $extensionToMimeTypeMap;

		if (!$extensionToMimeTypeMap)
		{
			$extensionToMimeTypeMap = static::getExtensionToMimeTypeMap();
		}

		if (isset($extensionToMimeTypeMap[$extension]))
		{
			return $extensionToMimeTypeMap[$extension];
		}
	}
public static function detectByFileExtension($extension)
	{
		static $extensionToMimeTypeMap;

		if (!$extensionToMimeTypeMap)
		{
			$extensionToMimeTypeMap = static::getExtensionToMimeTypeMap();
		}

		if (isset($extensionToMimeTypeMap[$extension]))
		{
			return $extensionToMimeTypeMap[$extension];
		}
	}
public static function detectByFileExtension ( $ extension ) { static $ extensionToMimeTypeMap ; if ( ! $ extensionToMimeTypeMap ) { $ extensionToMimeTypeMap = static :: getExtensionToMimeTypeMap ( ) ; } if ( isset ( $ extensionToMimeTypeMap [ $ extension ] ) ) { return $ extensionToMimeTypeMap [ $ extension ] ; } }
Detects MIME Type based on file extension.

@param   string  $extension
@return  mixed   string|null MIME Type or NULL if no extension detected
Detects MIME Type based on file extension .