Documentation
Browse by topic
Explore related documentation through its most useful keyword groups.
1031 items
Grouped by Architecture
A named transformation applied to a value inside a template expression.
Explore this clusterA typed event or request exchanged between decoupled Zotonic components through the notifier.
Explore this clusterA server-defined browser action or event binding connected through Zotonic wires.
Explore this clusterAn OTP application or site component that adds Zotonic behavior templates data and configuration.
Explore this clusterA namespaced interface for retrieving or changing data from Erlang templates MQTT or APIs.
Explore this clusterA server-side template_compiler document that renders data into HTML text email or another representation.
Explore this clusterA request handler that maps web requests to responses and coordinates authorization rendering or data transfer.
Explore this clusterA route declaration that matches a URL pattern and selects a controller with arguments.
Explore this clusterThe central Zotonic entity that represents content users media categories and other addressable objects.
Explore this clusterDocumentation not covered by the other keyword groups in this split.
Explore this clusterConverts a text into a slug.
The sort filter takes a list of items to sort. Items can be an ordinary list of terms, property lists, or maps. It can also be a list of resource ids to be…
Mark an element as sortable.
A sorter is a container for sortables.
Removes whitespace between HTML tags.
Add an AJAX activity indicator.
Splits the filter value into a list of values.
This filter split a list in shorter lists. It splits an array in N sub-arrays of more or less equal length. This is useful when displaying a list of items in…
Model for Let's Encrypt status information, available to administrators.
Some interesting tidbits about saving/updating a date/time field of a resource.
Translates atoms, integers and floats to strings. The undefined value is translated to the empty string. Does not translate tuples.
Removes all HTML tags from the value.
Subtracts a day from a date. The value must be of the form {{Y,M,D},{H,I,S}} .
Subtracts an hour from a date. The value must be of the form {{Y,M,D},{H,I,S}} .
Submits the enclosing form, a specifically targeted form or the closest form to an element.
Subtracts a month from a date. The value must be of the form {{Y,M,D},{H,I,S}} .
Subtracts a week from a date. The value must be of the form {{Y,M,D},{H,I,S}} .
Subtracts a year from a date. The value must be of the form {{Y,M,D},{H,I,S}} .
Sum a list of numbers.
Extract a summary from a resource.
Model for survey reporting and participant state, including results, totals, per-user answers, exports, and result handlers.
Filter to split multi-value survey answers on the '#' character.
Determine if any answer of a question was correct. Used for showing results of thurstone test questions.
Determine if any answer of a question was wrong. Used for showing results of thurstone test questions.
Split the page blocks into pages, prepare them for easy display in the survey question editor.
Test whether a survey respondent may return to the previous page in a history.
Check if a list of questions contains a pagebreak block with an unconditional submit.
Check if the given survey is configured to save intermediate results. Always returns a boolean value.
Check if there is a ‘stop’ question in list of (survey) blocks
Check if the questions end with a question type that is a submit button.
Check the list of blocks and collect all options for that page.
Prepare the items and options of a survey matching question for rendering.
Parse a survey narrative question into renderable text and input parts.
Normalize a survey Thurstone question before rendering or processing it.
Used by the survey module to add extra column values to the result editor.
Model for saving and retrieving intermediate survey answers for users. There can only be a single intermediate result per user/survey or, for anonymous users…
Show the first page for a given survey (with the id parameter):
Counts the total of all points that can be received for all test questions. Non test questions are not counted.
Note
Make a HTML element into a tab set.
Fetch the tail of a list.
Render a template. When used in a postback action, the result will be sent back with the response data for the postback.
Model for dynamic template rendering. It renders a template path passed in the request path and returns the rendered template output.
This chapter lists some preferred solutions to common tasks and pitfalls you may encounter while developing with templates.
Templates are text files marked up using the Zotonic template language. Zotonic interprets that mark-up to dynamically generate HTML pages. Zotonic’s template…
Not implemented, but exists in Zotonic for forward compatibility with future ErlyDTL and Django versions.
Creates a temporary resource if its input value is not defined.
It is possible to create end-to-end integration tests for Zotonic websites. Tests like these are called sitetests . They run within the Zotonic shell
Adding a site to Zotonic is done through the zotonic shell command. It syntax is like this:
The Zotonic “status” site is the first thing you see once you have installed Zotonic, or if you do not have any sites configured yet.
Zotonic’s data model is a pragmatic implementation of the Semantic Web: a mixture between a traditional database and a triple store.
Show a readable version of a date/time difference.
Simple read-only interface to the typed key-value store of module#mod_tkvstore. To get a value from the store: use m.tkvstore.type.key, like this:
Convert the input to a binary value.
Convert the input to a boolean value.
Filter to derive a Table Of Contents from a HTML body.
Toggle the visibility of an element.
Toggle a CSS class from an HTML element.
Convert the input to an integer value.
Display any value as in JSON (JavaScript Object Notation).
Returns a list of tokens from input string, separated by the characters in the filter argument.
Map a string to a name . That is a lowercased string with only [a-z0-9_] characters.
Translate a text value using gettext.
Translate a text value using gettext and substitute variables.
Filters all empty translations from a property.
Return a list of all languages present in the given translated text ( #trans{} record).
Translates a (English) value to the current language or the given language.
Check all properties of a map, list or resource. Returns a list of all properties that are translated (have a #trans{} record) and their translations.
The m_translation model gives easy access to language and translation related information.
Many sites need to support content and templates in multiple languages. Luckily, Zotonic is completely multilingual, out of the box. mod_translation does all…
Lookup a specific translation in a translated text. If the text is not translated then the text is returned as-is.
Trigger a named {% wire %} event in the browser. The required name argument identifies the wire; every other action argument is passed to the named event.
Removes whitespace at the start and end of a string.
Installation Zotonic won’t start and shows errors when running zotonic debug Check your site’s database configuration.
Truncate a text to a maximum length.
Truncate a text to a maximum length in characters.
Truncate a HTML text to a maximum length.
Show possible selections whilst typing.
Removes HTML escaping from a text.
Remove an edge between two resources. Used in the admin.
Removes a mask that was placed over an element using the action#mask action.
Updates the content of an HTML element with a template or a literal HTML text.
Note
Ever wanted to update a form field from a dialog, possibly giving the user some list to choose from? Here’s how to do it.
These notes list the most important changes between Zotonic versions. Please read these notes carefully when upgrading to a new major Zotonic version.
Translates the value to upper case.
Generates the relative URL for the given dispatch information.
Generate the URL for a named dispatch rule. In this way it is possible to automatically change the generated URLs when the dispatch rules are modified.
Generates an absolute URL for the given dispatch information.
Decode a text where characters are encoded as URL-safe characters.
Make a text safe for URLs.
Find urls in the given input and make them clickable.
Render a named fragment defined with tag#fragment.
Render a named tag#fragment, pass it enclosed body content, and optionally override its named blocks.
The following environment variables influence how Zotonic starts up.
Welcome to the Zotonic User Guide. This guide is a non-technical introduction to Zotonic.
Create new users In the admin, under ‘Auth’ > ‘Users’ you can find a list of all users. Use the ‘Make a new user’ button to create a new user with a username…
Check if an entered username is unique by querying model#identity for the given username:
Using the Varnish HTTP frontend, you can speed up your Zotonic even more as this web server caches static files intelligently.
Translates a datetime from local time to UTC.