Text

All Text

length

Returns the length of the value.

admin_dispatch

Dispatch rules Name Path Resource Args admin_user [“admin”,”users”] controller_admin [{template,”admin_users.tpl”}

mod_admin_predicate

Add support for editing predicates in the admin, by presenting a list of all defined predicates on http://yoursite.com…

dialog_predicate_new

Show a dialog for creating a new predicate.

dialog_user_add

Show a dialog for adding a user. This creates a person resource and adds a username / password to it.

without

Remove the items given in the argument from the filter value.

template

Render a template. When used in a postback action, the result will be sent back with the response data for the postback.

Templates

template

observe_media_upload_preprocess/2

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

Best Practices

Creating sites Media Best Practices Template Best Practices and Pitfalls

observe_media_upload_rsc_props/3

Notification that a medium file has been uploaded. This is the moment to change resource properties, modify the file…

facebook

Not yet documented.

predicate

Retrieve information about predicates. Predicates are the labels on edges (connections between resources) that give…

Configuration

Global configuration Site configuration Port configurations

Resources

admin_merge_diff content_type_label content_type_urls summary temporary_rsc

mod_video

See also

controller_website_redirect

This controller does a redirect to the website property of the given resource.

controller_static_pages

Serve a static page or pages.

controller_signup_confirm

Controller which displays the confirmation page where the user can confirm his signup.

controller_signup

Controller which displays a form to sign up (rendered from signup.tpl ).

controller_redirect

Redirect to another url.

controller_mqtt_transport

Controller for transport of MQTT data between the browser (client) and server.

controller_mailinglist_export

Controller which downloads the given mailinglist id as a CSV file.

controller_logoff

Controller that logs off a user, destroying the session. It also removes any “remember me” cookies the user has, so…

controller_language_set

Controller which sets the language as given in the code argument, and redirects the user back to the page given in the…

controller_http_error

This controller is called for serving http error pages.

controller_admin_seo

Shows a form with settings related to Search Engine Optimization.

controller_admin_referrers

Shows the list of pages ( resources) which refer to this resource through an edge.

controller_admin_module_manager

Shows the list of Zotonic modules currently known to the system.

controller_admin_mailinglist_recipients

Shows the recipients of the current mailing list. The recipients are listed in three columns, and have a checkbox next…

controller_admin_mailinglist

This controller shows the mailing lists that are available in the system.

controller_admin_mailing_status

This controller shows the mailing status of a resource. It lists each mailing list available in the system, and shows…

controller_admin_config

Shows the admin config editor. Here you can edit the key/value pairs of m_config.

controller_admin_comments_settings

Shows an admin settings screen where you can edit settings related to mod_comment.

controller_admin_comments

Shows an admin screen with an overview of most recently created comments. The screen offers the option to moderate the…

controller_admin_backup_revision

Shows the admin backup revisions screen where you can see older version for a resource.

controller_admin_backup

Shows the admin backup screen where you can download nightly backups that were made by mod_backup.

Template Best Practices and Pitfalls

This chapter lists some preferred solutions to common tasks and pitfalls you may encounter while developing with…

mod_logging

See also

dispatch

Dispatch rules Name Path Resource Args admin_log [“admin”,”log”] controller_admin [{template,”admin_log.tpl”}

Authentication notifications

auth_checked auth_confirm auth_confirm_done auth_client_logon_user auth_client_switch_user auth_identity_types…

controller_authentication

This controller manages all authentication cookies. It is called by the auth model in the browser.

Media Best Practices

Use Media classes to define image properties.

dispatch

Dispatch rules Name Path Resource Args admin_category_sorter [“admin”,”category”] controller_admin_category_sorter…

admin_tasks

Action module which provides postback handlers for the “status” view of the admin:

Admin

admin_tasks redirect_incat

if

See also

is_defined

See also

exclude

See also

search

See also

chunk

See also

controller_admin_category_sorter

Shows the admin category screen where you can edit the category tree, rearranging the categories, adding new categories

Global template variables

These variables are always available for rendering in templates.

dispatch

Dispatch rules Name Path Resource Args admin [“admin”] controller_admin [seo_noindex] admin_overview_rsc [“admin”

observe_auth_precheck/2

First for logon of user with username, check for ratelimit, blocks etc.

escapejson

See also

escapejs

See also

observe_auth_options_update/3

Update the given (accumulator) authentication options with the request options.

dialog_new_rsc

Show the admin dialog for creating a new resource.

slugify

See also

dispatch

Dispatch rules Name Path Resource Args admin_seo [“admin”,”seo”] controller_admin_seo [seo_noindex]…

observe_survey_submit/2

A survey has been filled in and submitted.

validation_error

Render a validation error on the target. Text is given in the text argument.

mailinglist

Not yet documented.

replace_args

Replace $N placeholders in string from a list of replacement values.

dispatch_module_admin

Dispatch rules Name Path Resource Args admin_modules [“admin”,”modules”] controller_admin_module_manager…

observe_postback_notify/2

Handle a javascript notification from the postback handler. The message is the the request, trigger the id of the…

dispatch

Dispatch rules Name Path Resource Args admin_frontend_edit [“edit”] controller_page [{acl,is_auth},{template

slice

Perform array-slice operations on a list or string.

CMS

Zotonic is a Content Management System (CMS).

dispatch

Dispatch rules Name Path Resource Args admin_auth2fa_config [“admin”,”authentication-2fa”] controller_admin [{ssl

observe_dispatch_host/2

Try to find the site for the request Called when the request Host doesn’t match any active site.

observe_email_failed/2

Notify that we could NOT send an e-mail (there might be a bounce later...) The Context is the depickled z_email:send/2…

with_args

Apply actions with arguments added.