Example file

01-minimal.html

The paste-in snippet the dashboard gives you: a placeholder and the script.

To try this page, download it, replace the placeholders and put it on a test page of your website. Opening the file from your computer won't work, because the embeds check the website address they're on.

01-minimal.html · HTML Download
<!doctype html>
<!--
  The quote form as the dashboard gives it: a placeholder and the script.
  It needs no code of your own and no server. The form uses its key to get
  short-lived access tokens.

  Replace qfk_YOUR_KEY, YOUR_PRODUCT_SLUG and YOUR_JOURNEY_SLUG with your own
  values (the comment above the placeholder says where to find them).
-->
<html lang="en">
<head>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width, initial-scale=1">
  <title>Quote form: minimal paste-in</title>
</head>
<body>
  <h1>Minimal paste-in</h1>
  <p>
    The two lines from the quote form's page in the dashboard (under "The code to paste"). The script finds every
    <code>data-subcontext-quote</code> element once the page has loaded and draws a quote form in it.
  </p>

  <!--
    The quote form is drawn here. All three values are in "The code to paste" on the quote
    form's page in the dashboard (CRM, Campaigns, open the campaign, Lead capture tab):
      data-key:     the quote form's key (starts qfk_)
      data-product: the product it quotes
      data-journey: the journey it uses
    Optional: add data-presentation="YOUR_PRESENTATION_SLUG" for another of the journey's presentations.
  -->
  <div data-subcontext-quote data-key="qfk_YOUR_KEY" data-product="YOUR_PRODUCT_SLUG" data-journey="YOUR_JOURNEY_SLUG"></div>

  <!-- The quote form script. Put it once on the page, anywhere. -->
  <script src="https://js.subcontext.com/quoteform-latest.js" defer></script>
</body>
</html>

Stuck, or something missing?

Get in touch and a person on the team will help.

Contact us