Skip to content
Zotonic
  • Start
  • Cookbook
  • Reference
  • Releases

Live search

Search across all Zotonic content

Type at least two characters

Results are matched against titles, summaries and topics as you type.

Filters · mod_base
  • Reference
  • Frontend developer
  • Metadata
  • Template filter
  • Format

content_type_label

Module

mod_base

Return a translated, human-readable label for a MIME content type.

Known types have descriptive labels such as JSON, Excel Workbook, and iCalendar. Other types are represented by their uppercase file extension. The input can be a MIME type string or a parsed Cowboy media-type tuple.

For example:

{{ "application/json"|content_type_label }}

Edit on GitHub

Related documentation

Filters

media_exif_value

Formats EXIF values for display in templates.

Filters

mailinglist_delivery_detail

Extract the SMTP diagnostic from legacy {bounce, <<"...">>} and related mailing-run details, including nested errors and missing…

Filters

filter_payment_currency_symbol

Show a payment currency using its preferred symbol or short form.

Filters

humanize_identifier

Convert an underscore-separated identifier to a readable label.

Filters

format_dispatch_path_element

Format dispatch path element so variables will be more visible.

Filters

format_dispatch_controller_option

Format dispatch controller options.

Filters

upper

Translates the value to upper case.

Filters

date

Formats a date or datetime according to the format specified in the argument.

Filters

language_dir

Return rtl or ltr depening on the direction of the language.

GitHub © 2026 Zotonic