ResolveMimeType Method

Syntax

Context.ResolveMimeType as C (filename as C)

Arguments

filenameCharacter

The full file name or an extension.

Returns

ResultCharacter

Returns the MIME type of the given file name.

Description

Returns the MIME type of the given file name.

Discussion

Context.ResolveMimeType(filename as C) returns the MIME type of the given file name.

The filename parameter can be a full file name, or only an extension.

Example

'Place this code in <%a5 %> tags on an .a5w page

?Context.ResolveMimeType("index.html") + "<br/>"
?Context.ResolveMimeType(".json") + "<br/>"

'The output will be 
'text/html
'application/json