Skip to main content

How to Trigger Content from CTAs and Events

Launch Candu content when users click buttons, complete actions, or trigger events instead of showing it automatically.

Deborah Ramírez avatar
Written by Deborah Ramírez
Updated over 2 weeks ago

Need to show content when users click a button or complete an action, rather than automatically on page load? Here's how!

Before you get started

Most Candu content requires a placement to determine where and when it appears. However, when you want to launch content from CTAs or code, that content needs to be published without a placement first.

When to publish without a placement

You should publish content without a placement when it will be:

  • Triggered by Candu CTAs
    When one piece of Candu content launches another (like a button in a modal that starts a product tour), the triggered content doesn't need its own placement.

  • Used in "Change Content" interactions
    Overlay content that swaps in when users interact with existing content doesn't need a separate placement, it inherits visibility rules from the parent content.

  • Triggered programmatically
    Modals, tours, and hotspots can be triggered when specific events occur in your app using Candu's JavaScript API. Inline content can also be rendered programmatically. See our developer documentation for implementation details.

URL parameters let you launch tours, modals, and hotspots automatically when users click a link. Learn more about Candu's built-in URL parameters.

How to Publish Without a Placement

  1. Click Publish in the Editor

  2. Select your target segments

    Note: Segmentation rules still apply. Only users matching your segments will see this content when triggered.

  3. When prompted to add a placement, click Publish without a placement

Your content is now ready to be triggered.

How to Trigger Your Content

From a Candu CTA (opens new content):

  1. In your triggering content, select the call-to-action (button/link)

  2. In the Interactions panel, add the "Trigger" action

  3. Select your published content from the dropdown

From a "Change Content" interaction (swaps content):

  1. In your parent content, select the call-to-action (button/link)

  2. In the Interactions panel, add the "Change Content" action

  3. Select your published overlay content from the dropdown

Did this answer your question?