Dialogs Framework Basic Concepts

Dialogs Feature: Page and List Automation scripts

Updated: 21 Apr 2023


Dialogs separates content from design. Lists define the content containers for a Dialogs website; Templates define the design or presentation for a Dialogs website. List fields CANNOT contain php code (for security reasons among others) but Templates can. Page Automation scripts and List automation scripts extend the opportunities for Developers to customize Dialogs behavior.

Page Automation Scripts

Often it is handy to define functions or variables that are available only to a specific page. Developers may place such code in a Page Automation script that is included at page render. This is done by entering the name of the automation script (often including the page name by convention, e.g. "index.inc.php") in the Page Automation field of the Page Detail View. The script will be saved in the /inc/ directory. If the script does not exist, Dialogs will create a skeleton script for later customization. Page Automation scripts can include any php code and can make use of Dialogs functions to interact with the Dialog database. Page Automation scripts are often used to interact with external data sources such as googleMaps, eCommerce gateways, etc.

List Automation Scripts

Frequently it is convenient to execute code upon the POST of a form that interacts with a Dialogs List. This is done by entering the name of the automation script (often including the list name and "post" by convention, e.g. "orders.post.inc.php") in the List Automation field of the Detail View for a List. The script will be saved in the /inc/ directory. If the script does not exist, Dialogs will create a skeleton script for later customization. List Automation scripts can include any php code and can make use of Dialogs functions to interact with the Dialog database. List Automation scripts are typically used to update related lists, strip fields of inappropriate content, interact with external data sources, send emails, etc.

 

Next: Dialogs Feature: RSS

LinkedInFacebookYouTubeTwitter