Hide

YetaWF Documentation

Display
Print

MimeSettings.json

The file MimeSettings.json defines all MIME types allowable by YetaWF, for upload, display or any other use as defined by other packages. The file can be found in the website's Data folder.

MimeSection.MimeTypes

This section defines the file extensions that are allowed to be used with YetaWF.

Default entries for commonly used file types are automatically defined when YetaWF is installed.

Each MimeTypes entry defines one file type using the following attributes:

AttributeTypeDescription
TypeContent-TypeDefines the Content-Type used for up/download.
ExtensionsstringOne or multiple semi-colon separated file extensions that are allowed for this file type.
PackageUsebooltrue if this file type can be used as a package file (ZIP file), false otherwise, which is the default. Used for YetaWF package uploading.
ImageUsebooltrue if this file type can be used as an image file, false otherwise, which is the default. Used for image uploading.
FlashUsebooltrue if this file type can be used as a Flash image file, false otherwise, which is the default. Used for Flash image uploading.
Additional TypesboolPackages can define their own types (always prefixed by the package name, e.g. Softelvdm_DropBoxUse or YetaWF_TestDocUse).
MimeSettings.json
{
  "MimeSection": {
    "MimeTypes": [
      {
        "Type": "text/plain",
        "Extensions": ".txt;.css;.scss;.less"
      },
      {
        "Type": "text/html",
        "Extensions": ".html;.htm"
      },
      {
        "Type": "image/gif",
        "ImageUse": true,
        "Extensions": ".gif"
      },
      . . .