How do I deploy an embedded form?

Sometimes it can be useful to put the form in the content of your page. This is how to do it:

Step 1: Create an embedded form

Edit the form and set it to Embedded in the form tab in the build step:

Step 2: Add form to deployment

Then go to the deployments and add the form to the deployment and leave the trigger method at “Triggered by button”:

Step 3: Edit the form placement options

Scroll down to view the form placement options. For embedded forms, it’s important to edit these. Turn off the toggle for “Append div to body of the page if not found”. If this toggle is on and the settings on the website are incorrect the form will be placed at the bottom of the page. This is probably an incorrect position.

Step 4: Choose a name for the selector

Then at the “Render form into” option choose a name for the selector you want to use to specify the location of the form on the page. If you are using a single form on the page you can simply change the name of the div. In this case, we use the id surveyContentEmbed.

Step 5: Set the conditions and add the code

Then also set the other conditions relevant to your form and save the deployment.

To show the form on the page you have to add a div with the chosen id. In this case the div will be the following: <div id=”surveyContentEmbed”></div>

Video Walkthrough