Text

All Text

observe_media_preview_options/3

Modify the options for an image preview url or tag. This is called for every image url generation, except if the…

Other cookbooks

Create a custom action Create a custom filter Create a custom model Create a custom controller Custom pivots Create a…

Shell cookbook

Activate/deactivate modules Filter and convert characters Erlang tab completion Debugging db (query) issues Reset a…

Just enough…

These Cookbook items each represent a stage in some Zotonic users’ journeys to understand the workings of Erlang and…

Frontend cookbook

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

Admin cookbook

Creating a custom widget on the edit page Customizing the layout of the admin edit page Customizing the style of an…

menu_expand

Takes a menu, or a menu resource id, and adds all haspart objects connected to the menu ids.

language_dir

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

0.63.0

Welcome to Zotonic 0.63.0, released on Oct 29, 2021.

sub_hour

See also

add_hour

See also

parse_url

Parses an URL (URI) using uri_string:parse/1 .

oauth2_consumer

Not yet documented.

controller_ping

Simple controller for connection tests, used on the /test/connection page.

is_site_url

See also

URLs and links

is_site_url url url_abs sanitize_url is_letsencrypt_valid_hostname urlize escape_link urlencode urldecode parse_url…

image_edit

See also

Create a custom controller

Zotonic comes with a large collection controllers that cover many use cases, so you’ll probably have to resort to…

0.62.0

Welcome to Zotonic 0.62.0, released on July 7, 2021.

signup

Exported APIs:

0.61.0

Welcome to Zotonic 0.61.0, released on June 7, 2021.

seo_sitemap

Not yet documented.

sanitize_html

Sanitize a HTML code. Removes elements and attributes that might be dangerous, like <script\> elements.

sanitize_url

Sanitize an URL. Removes URLs that might be dangerous, like javascript: URLs.

toc

Filter to derive a Table Of Contents from a HTML body.

dispatch-test

Dispatch rules Name Path Resource Args initial_test [“test”,”initial_postback_test”] controller_template…

dispatch

Dispatch rules Name Path Resource Args microsoft_authorize [“oauth-service”,”authorize”,”microsoft”]…

microsoft

Check with useauth if the authentication using the Microsoft identity platform is enabled and configured.

mod_microsoft

Adds logon using the Microsoft identity platform.

dispatch

Dispatch rules Name Path Resource Args fileuploader [“fileuploader”,”upload”,name] controller_fileuploader []…

fileuploader

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

controller_fileuploader

The fileuploader controller is used to upload parts of a file.

mod_fileuploader

Upload files using a parallel web worker.

0.60.0

Welcome to Zotonic 0.60.0, released on February 15, 2021.

0.59.0

Welcome to Zotonic 0.59.0, released on December 18, 2020.

site_update

Model for checking if a site has version control enabled.

mod_site_update

This module pulls updates of a site‘s code from a remote version control system. The supported version control systems…

url_abs

See also

url

See also

0.58.0

Welcome to Zotonic 0.58.0, released on November 2, 2020.

The Rationale of Zotonic

Zotonic is a modern and extensive content management system. It has its roots in systems before it and carries the…

0.56.3

Welcome to Zotonic 0.56.3, released on August 31, 2020.

0.54.3

Welcome to Zotonic 0.54.3, released on August 31, 2020.

mod_audio

See also

0.54.2

Welcome to Zotonic 0.54.2, released on August 4, 2020.

dispatch

Dispatch rules Name Path Resource Args oauth2_consumer_authorize [“oauth-service”,”authorize”,”zotonic”

oauth2_service

Not yet documented.

mqtt_ticket

A ticketing system for out of band MQTT posts via HTTP.

email_dkim

DomainKeys Identified Mail Signatures (RFC 6376) is a method to add a signature to outgoing emails. This enables…

0.54.1

Welcome to Zotonic 0.54.1, released on June 16, 2020.

0.56.1

Welcome to Zotonic 0.56.1, released on June 16, 2020.

Directory structure

Zotonic is a set of regular OTP applications. These can be found in the repository’s apps/ directory:

Reference

All the nitty gritty details when the big picture has settled.

mod_acl_mock

Mocking module for access control during tests.

User Guide

Welcome to the Zotonic User Guide. This guide is a non-technical introduction to Zotonic.

linkedin

Not yet documented.

admin

This model exposes some meta-information for the use in mod_admin templates.

ACL options

Authorization checks to perform, in addition to the acl_action dispatch option, can be given in the acl dispatch option

observe_edge_insert/2

An edge has been inserted. Note that the Context for this notification does not have the user who created the edge.

observe_auth_validated/2

Authentication against some (external or internal) service was validated

mod_import_wordpress

Import WordPress .wxr files in your site.

media_import_props

Notification to translate or map a file after upload, before insertion into the database Used in mod_video to queue…

observe_media_stillimage/2

See if there is a ‘still’ image preview of a media item. (eg posterframe of a movie) Return:: {ok, ResourceId} or…

observe_tkvstore_put/2

Put a value into the typed key/value store

observe_tkvstore_delete/2

Delete a value from the typed key/value store

observe_security_headers/2

Check and possibly modify the http response security headers All headers are in lowercase.

observe_scomp_script_render/2

Add extra javascript with the \{% script %\} tag. (map) Used to let modules inject extra javascript depending on the…

observe_module_deactivate/2

A module has been stopped and deactivated.

observe_m_config_update/2

Site configuration parameter was changed

observe_language/2

Notify that the session’s language has been changed

observe_dispatch/2

Final try for dispatch, try to match the request. Called when the site is known, but no match is found for the path

observe_admin_rscform/3

Used in the admin to process a submitted resource form

observe_activity/2

An activity in Zotonic. When this is handled as a notification then return a list of patterns matching this activity.

observe_action_event_type/2

Render the javascript for a custom action event type. The custom event type must be a tuple, for example: `{% wire…

dispatch_translation

Dispatch rules Name Path Resource Args admin_translation [“admin”,”translation”] controller_admin [{acl_module

dispatch

Dispatch rules Name Path Resource Args signup [“signup”] controller_signup [] signup_confirm [“signup”,”confirm”]…

dispatch_mailinglist

Dispatch rules Name Path Resource Args admin_mailinglist [“admin”,”mailinglists”] controller_admin_mailinglist…

development

Dispatch rules Name Path Resource Args admin_development [“admin”,”development”] controller_admin [{template

dispatch

Dispatch rules Name Path Resource Args admin_custom_redirect [“admin”,”custom-redirect”] controller_admin…

dispatch

Dispatch rules Name Path Resource Args admin_predicate [“admin”,”predicate”] controller_admin [{acl_module

dispatch

Dispatch rules Name Path Resource Args admin_config [“admin”,”config”] controller_admin_config [seo_noindex]…

dispatch

Dispatch rules Name Path Resource Args acl_rule_test [“acl”,”rules”,”test”] controller_template [{template

observe_media_replace_file/2

Notification that a medium file has been changed (notify) The id is the resource id, medium contains the medium’s…

dispatch-cotonic

Dispatch rules Name Path Resource Args mqtt_transport [“mqtt-transport”] controller_mqtt_transport []…

email_receive_recipient

Not yet documented.

ssl_letsencrypt

Not yet documented.

filestore

The filestore uses two tables for its administration.

dispatch

Dispatch rules Name Path Resource Args admin_comments [“admin”,”comments”] controller_admin_comments [seo_noindex]…

dispatch

Dispatch rules Name Path Resource Args zotonic_sites_add [“zotonic”,”sites”,”add”] controller_zotonic_status…

observe_edge_update/2

An edge has been updated Note that the Context for this notification does not have the user who updated the edge.

observe_auth_logon/3

User logs on. Add user-related properties to the logon request context.

observe_pivot_update/3

Pivot just before a m_rsc_update update. Used to pivot fields before the pivot itself.