Write Log Message
Last updated
Last updated
Block Information
Available in: Page Flow and Cloud Flow
Toolbox Category: Action - Log
Block Type: Regular
The Write Log Message
block is available in Page Flow and Cloud Flow and operates in similar ways with some minor differences.
In Page Flow this block allows you to write messages into the browser's web console log, whereas in Cloud Flow it writes a message into the Zingy's cloud logs, which can be accessed from the Cloud Flow tab in the App Editor.
The block consists of the following:
Message: a Value Parameter that accepts a text value for the message you want to log.
Category: a Value Parameter that accepts a text value that specifies the category of the message. This is useful for filtering out messages when conducting a post-mortem or debugging.
Level: a Value Parameter that accepts a numeric value specifying the severity level of the message. This is only supported in Cloud Flow and is useful for further filtering out messages when conducting a post-mortem or debugging.
The example below shows the Write Log Message block used when the a button is clicked. The message "The button was clicked" is written to the log.
For the Category value parameter, we use the Log Category block with the INFO category selected.
Note: You can provide your own categories and do not have to use the Log Category block.
This would produce a message similar to the one below: