Links
Comment on page

Button

This element will display a button that, according to its type, will have a color meaning different status:
You may add a button at the and of your form in order to trigger a custom action. This component supports the following attributes:
Property
Description
Values
type
The type of button.
  • primary: Default blue button
  • success: Green button
  • warning: Orange button
  • danger: Red button
  • muted: Gray button
click
A user-defined label that serves as a unique ID to link the button to an action.
Any user-defined label that matches the label of any of the supported actions.

Supported button actions

Available actions inside the custom UI widget are:
  • Trigger webhook: Upon clicking the button, an HTTP request will be made to the configured URL.
  • Go to dashboard: Upon clicking the button, the configured dashboard will be launched in a new tab.
  • Go to URL: Upon clicking the button, a new tab will be launched pointing to the designated URL.

Example

The following code snippet displays a green button, that, upon being clicked, will launch the action labeled make_request, that will ultimately make an HTTP POST request to a certain configured Ubidots endpoint:
<button type="success" click="make_request">Send</button>
Here, the button's property click defines the label of the action to be performed ("make_request") and which is configured in the widget's settings, at the "actions" section: