Text

All Text

regroup

Not implemented tag, for forward compatibility with future ErlyDTL and Django versions.

raw

Make a literal section which does not interpret tags.

now

Show the current date and time.

media

Show embed, video or audio media.

load

Loads the given custom tags for use in the templates. Normally not needed, as custom tags are automatically loaded…

lib

Combine css and javascript includes in a single request.

javascript

Adds javascript that will be run after jQuery has been initialized. In dynamic content it will run after the DOM has…

inherit

Include the markup of an extended template into the extending template.

image_url

Generate the url of a still image.

image_data_url

Generate a data: url of a still image.

ifnotequal

Show a block when two values are not equal.

ifequal

Show a block when two values are equal.

ifchanged

Not implemented, but exists in Zotonic for forward compatibility with future ErlyDTL and Django versions.

if

Show a block if the condition is true.

for

Loop over multiple values in a list or search result.

firstof

Not implemented, but exists in Zotonic for forward compatibility with future ErlyDTL and Django versions.

filter

Filter the contents of a block through variable filters.

cycle

Rotate through a list of values.

comment

Ignore part of a template.

call

Call an Erlang function.

cache

Cache a frequently used block for later reuse.

autoescape

Automatically apply HTML escaping to values.

all include

Call all modules to include a certain template.

all catinclude

Include a template for all a resource’s categories from all modules.

Modules

Modules are the building blocks of Zotonic. They add functionality to your Zotonic website such as:

Templates

Templates are text files marked up using the Zotonic template language. Zotonic interprets that mark-up to dynamically…

Release 0.12.2

Released on 2014-12-18 17:01 by mworrell.

email_ensure_handler

Add a handler for receiving e-mail notifications

user_context

Set #context fields depending on the user and/or the preferences of the user.

overrules

Inherit markup from like named template in another module.

extends

Inherit markup from another template.

block

Define a block in a template and overrules a block from an inherited template.

element

Select an element from a tuple or list of tuples.

Tuples

element

mod_email_dkim

Signs outgoing e-mails with DomainKeys Identified Mail Signatures ( RFC 6376).

show_media

Convert the image markers in HTML from the Rich Text editor into image tags.

image

Show a still image using an <img> element. The image will be automatically resized to the desired size and filters. For…

as_atom

Convert a value to an Erlang atom.

update

Updates the content of an HTML element with a template or a literal HTML text.

insert_top

Inserts HTML before the contents of an HTML element.

insert_before

Insert the result of a render action before an HTML element.

insert_after

Insert the result of a render action after of an HTML element.

insert_bottom

Inserts HTML after the contents of an HTML element.

menu_rsc

Return the menu to be displayed with a resource.

mod_admin

Extending the admin menu See m_admin_menu on how to extend the admin menu.

controller_admin

The admin controller is the main controller behind which admin pages are served. Its main purpose is that it does an…

mod_filestore

Support for storing uploaded and generated images and documents on external services.

dispatch

Dispatch rules Name Path Resource Args admin_filestore [“admin”,”filestore”] controller_admin [{template

wire

Connect actions and events to a HTML element.

include

Include another template. The include tag is replaced with the contents of the included template file. You can give…

catinclude

Include another template based on the category of a resource. The include tag is replaced with the contents of the…

mod_mqtt

MQTT is a machine-to-machine (M2M)/“Internet of Things” connectivity protocol. It was designed as an extremely…

live

Live updating templates connected to MQTT topics.

auth_confirm

Confirm a user id.

inject_recipientdetails

Adds recipient query string details to hyperlinks.

Mailing list

inject_recipientdetails mailinglist_recipient_key_decode

Server configuration

This chapter describes how to configure your Linux server for running Zotonic.

Exometer metrics

Zotonic comes with a system for collecting and exporting metrics (such as how much memory is used, how many database…

Release 0.29.0

Welcome to Zotonic 0.29.0, released on 5 June, 2017.

mod_survey

Adds the concept of survey resources: user-definable forms which can be created in the admin interface and filled out…

survey_as_pages

Split the page blocks into pages, prepare them for easy display in the survey question editor.

menu_save

Save the menu tree of a menu resource

stringify

Translates atoms, integers and floats to strings. The undefined value is translated to the empty string. Does not…

to_binary

Convert the input to a binary value.

export_resource_visible

mod_export - Check if the resource or dispatch is visible for export.

random

Returns a random value from a list of values. When the input is an empty list or not a list then the result is…

rand

Generates a random number. The number is from, and including, 1 up to, and including, the input value.

randomize

Shuffle a list of values.

mod_server_storage

Server side storage for the client (aka browser) and server.

mod_authentication

This module contains the main Zotonic authentication mechanism. It contains the logon and logoff controllers, and…

dispatch

Dispatch rules Name Path Resource Args logoff [“logoff”] controller_logoff [] logon [“logon”] controller_template…

Release 0.8.1

Released on 2012-08-11 16:36 by arjan.

mod_wires

Actions, tags (also known as screen components), and javascript for user interfaces using wires .

Browser/server interaction

There are multiple ways to set up interaction between server-side Zotonic code and client-side JavaScript.

script

This tag is the placeholder where all generated JavaScript scripts will be output on the page.

print

Show the contents of a value expression.

date

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

m_edge

Access information about page connections.

mod_base

mod_base is the base module, which acts as a container module holding most of Zotonic basic dispatch rules, Actions and…

group_title_firstchar

Similar to group_firstchar, but always uses the title column from the rsc table.

group_firstchar

Group a list of sorted resource ids on their first letter of the title or another rsc property. After grouping, it…

mod_seo_sitemap

Creates a sitemap.xml file for your site, containing links to all publicly accessible pages.

menu

Show a page menu.

Displaying a site map

For the benefit of search engines and fans of tables of contents you can easily provide a site map.

mod_bootstrap

Adds support for the Twitter Bootstrap CSS / JavaScript framework.

mod_menu

Create nested navigation menus for your site.

dispatch

Dispatch rules Name Path Resource Args admin_menu_hierarchy [“admin”,”hierarchy”,name] controller_admin [{template

m_rsc_gone

This model tracks deleted resources (see m_rsc). Its primary goal is to be able to determine if a resource never…

m_identity

The m_identity model manages usernames and other user identities. mod_authentication uses it to store and check salted…

m_media

Access to data about uploaded files and other media.

m_category

This model can retrieve information about the resource category hierarchy in different ways.

Pivot Templates

Search uses database indices on special pivot columns and full text fields.

Custom pivots

Search can only sort and filter on resources that actually have a database column. Zotonic’s resources are stored in a…

Media

Resources can have media resources attached to them. Resources and their media (images, video and audio) are connected…

Glossary

Action An action is functionality that can be attached to a HTML element or event. Actions are wired to an element or…

m_rsc

The main resource model, which is the central part of the Zotonic data model. This model provides an interface to all…