Civetweb API Reference

mg_get_builtin_mime_type( file_name );

Parameters

ParameterTypeDescription
file_nameconst char *The name of the file for which the MIME type has to be determined

Return Value

TypeDescription
const char *A text string describing the MIME type

Description

The function mg_get_builtin_mime_type() tries to determine the MIME type of a given file. If the MIME type cannot be determined, the value text/plain is returned. Please note that this function does not an intelligent check of the file contents. The MIME type is solely determined based on the file name extension.

See Also