Page triggers, called Page Events in the page builder, run a function from a page: when it loads, or when a visitor clicks a button.
On Page Load
Runs once each time a visitor opens the page. Use it to load data.
Manual
Runs when something asks for it, such as a button. Use it for actions like saving or deleting.
Variables can also run functions: a variable's On Change Rules run a function when its value changes, equals a value, or passes a comparison.
1
Open Page Configuration
In the page builder, open Page Configuration and choose Page Events.
2
Click Add Page Event
Enter a Label / ID. Buttons refer to the trigger by this label, so keep it unique on the page.
3
Choose type and action
Pick the Trigger Type, then set Action type to invokeFunction.
4
Choose the function
Pick it in Select Function, then click Edit Function Inputs & Outputs.
5
Save
Click Update Page.
Page Configuration also holds Page Variables. Declare the variables your trigger fills before you map them.
Under Input targets, give each function input either the current value of a page variable or a fixed value.
Under Output targets, write each function output into a page variable. Declare the variable first, with the same type.
The output names are the names of the function's Output node ports.
For a detail page, send the row's uuid from the page, and have the function also filter by the signed-in user with Get User ID. A uuid in an address is something anyone can try.
1
Select the button
Open its settings in the page builder.
2
Set Button Action
Choose Trigger a page event.
3
Pick the trigger
Choose it in Select Event to Trigger.
Table rows can run page events too, through their Custom Table Buttons.
A trigger can turn one function output into a notification. In Show result as a notification, enter the name of the output that holds a notification code. Then enter the Success value.
When the output equals the success value, a success notification appears.
Any other non-empty value shows an error notification.
An empty value shows nothing.
It fires after every run, even when the value is the same as last time.
The code is translated like any other system message, so add its title and description text in Translations.
A custom component has its own page events. A trigger inside it can use the emitParentEvent action with a Parent Event ID to run a manual trigger of the page it is placed on.
This is how a button inside a repeated card asks the page to do something, such as refreshing a list after a row is removed.