Features/Forms

Custom success state

Replace the form with your own designed success or error block, or show a custom text message.

Every form has a Success Message and a Fail Message. For more control you design the success state yourself: put any element with the class dh-form-success inside the form. After a successful submit the form is replaced by that element and the class is removed so it becomes visible. The same works for errors with dh-form-fail. Builder forms have their own success and fail blocks (.dh-fb-success, .dh-fb-fail). On success the steps and actions are hidden and the success block is shown; the fail block shows for 5 seconds.

How it works

  • Platform CSS hides .dh-form-success and .dh-form-fail by default.
  • Hand-made form: first descendant .dh-form-success (any depth) replaces the form's content on success; .dh-form-fail on failure; otherwise the response message is shown as plain text.
  • Builder form: .dh-fb-success / .dh-fb-fail rendered from successMessage / failMessage.
  • Messages are always rendered as text, never HTML.
  • The Success and Fail messages are also editable in the dashboard form settings (General tab).
  • MCP: messages must be plain text (no < or >).

When to use it

  • A success card with an icon and a link to book a call
  • A friendly error block with a phone number

Limitations

  • Messages are plain text; HTML in the message is shown literally.

Availability

  • Works in Designer, AI Studio and MCP.

How to use it.

  1. Inside your form add a Div with the class dh-form-success and design it.
  2. Optionally add a Div with dh-form-fail.
  3. Publish; the blocks stay hidden until a submit.

Related features.

No card needed

Build it today.Pay when it goes live.

Every feature is unmetered while you build. Checkout opens the first time you publish.