Documentation

All Documentation

escape_link

See also

escapexml

Escape the value for insertion in xml output.

event

Bind actions to a jQuery event or submit a form.

Events

postback trigger_event publish

exclude

See also

Execute tasks asynchronously using the task queue

The Zotonic task queue lets applications perform tasks asynchronously.

Exometer metrics

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

extends

See also

facebook

Not yet documented.

fade_in

See also

fade_out

See also

filesizeformat

This filter formats a numeric value as KB, MB etc. This filter can be used to display a number of bytes in a human…

filestore

The filestore uses two tables for its administration.

fileuploader

Model to start uploads, upload a block and delete uploads.

filter

Filter the contents of a block through variable filters.

filter

See also

Filter and convert characters

Applying Erlang Binary syntax to get fast character manipulation.

first

See also

firstof

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

flatten_value

Flatten a list to a comma separated string.

focus

Add a $(..).focus() jQuery call to the target element to give it input focus.

for

Loop over multiple values in a list or search result.

format

See also

format_dispatch_controller_option

Format dispatch controller options.

format_dispatch_path_element

Format dispatch path element so variables will be more visible.

form_reset

Resets the target form to its initial state.

Forms

pickle

Forms

disable enable event focus form_reset reset set_value submit typeselect validation_error

Forms and validation

You should validate all input data entered in forms. In Zotonic you create forms by writing plain HTML. You can attach…

from_json

Parse a string as a JSON (JavaScript Object Notation) value. The returned value can be processed futher.

Frontend cookbook

These cookbook entries contain valuable nuggets of information regarding the frontend development of a site.

Getting Started

You have three options for running Zotonic: to get started quickly, start our Zotonic container. You can also use Nix…

Global configuration

This section describes the location and contents of Zotonic’s global configuration files erlang.config and zotonic.

Global template variables

These variables are always available for rendering in templates.

Glossary

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

google_chart

Make charts with Google.

gravatar_code

Calculate the gravatar code for an e-mail address:

group_by

Groups items of a list by a property.

growl

See also

hasedge

A validator to check if a resource has a certain number of edges with a predicate.

hide

See also

hierarchy

The category hierarchy tables have been replaced by m_hierarchy . This model defines named hierarchies of resources…

How to add a custom page block

Zotonic comes with a number of standard page blocks: Header, Text and Embed page. Additional page blocks are provided…

How to customise error pages

Specific error pages Zotonic’s controller_http_error first tries to find an error page template that is specific for…

HTML

show_media striptags truncate_html sanitize_html sanitize_url urlize embedded_media without_embedded_media render…

HTTPS support

Zotonic has built-in support for HTTPS and TLS (previously SSL) certificate handling.

Icons

Including Zotonic icons CSS Add the CSS file to your template:

Icons in templates

Zotonic provides a couple of ways to show icons in templates:

identity

See also

if

See also

if

See also

ifchanged

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

ifequal

See also

ifnotequal

See also

image

See also

image_edit

See also

image_url

See also

Implementing a simple contact form

This tutorial teaches you to create a form, validate it, submit it over Ajax and e-mail the results back to you.

import_csv_data

Not yet documented.

Import/export notifications

import_csv_definition import_resource export_resource_content_disposition export_resource_content_type…

include

See also

index_of

See also

in_future

See also

inherit

See also

inject_recipientdetails

Adds recipient query string details to hyperlinks.

in_past

See also

inplace_textbox

Render a JS-aided inplace textbox.

insert

See also

insert_after

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

insert_before

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

insert_top

See also

Installation requirements

Zotonic runs on Linux, Mac OS X and (not officially) on Windows.

Introduction

This is the Zotonic Developer Guide. It takes you through all aspects of Zotonic so you can start building your own…

ip2country

Maps an IP address to a country using the MaxMind GeoIP2 database.

ip2geo

Maps an IP address to information about that country.

is_a

See also

is_defined

See also

is_even

Test if an integer value is even:

is_list

Test if a value is a list:

is_not_a

See also

is_number

Test if a value is a number (integer or floating point):

is_rtl

See also

is_site_url

See also

Issues and features

If you encounter any issues in using Zotonic, or have ideas for new features, please let us know at the Zotonic issue…

is_visible

See also

javascript

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