Note: This guide applies to the Starter, Business & Scale plans.
In this article we will be taking a look at on how to embed Trustmary's testimonials and surveys to a web site when using Duda as the content management system. In this example, we will be using the testimonial embed. If you're looking for instructions on the same subject but for a different platform, please refer to the other articles in our Help documentation's Integrations section.
Getting the code snippets
Start by navigating to the Widgets section in Trustmary. In there, select a widget or create a new one.
In the widget editor, select the Add to website tab at the top of the screen. Here you'll find the code snippets needed to embed the widget.
What to do with the snippets?
Note, that the two snippets of code serve different purposes.
The first snippet, Trustmary tag, is a global script which enables the loading of the widgets. This script needs to be installed once, either with Google Tag Manager or inside the <head> tag of a website. We recommend installing the script with Tag Manager, as scripts installed like this are activated more reliably. For the installation process, check out this guide.
The second snippet is the embed code itself. This snippet loads a widget into where it is placed on the site.
Embedding the code in Duda
Optional: Add the header script manually
If you already installed Trustmary tag with Google Tag Manager, you don't need to worry about this step.
In the editor, navigate to SEO & Settings from the toolbar on the left. In there, find Head HTML, and under that a text box with the same name. Paste the script here and your widgets will start loading.
Start by selecting Widgets from the toolbar on the left in Duda's editor. In here, look for the HTML widget, and once you've found it, drag the widget onto its place on the site.
After the widget is placed on the page, a window pops up. Simply paste the embed code from before into this box (note that there might be some placeholder text in the box which you will need to remove before pasting the code).
Then just click Update in the lower right corner to save the changes.
Your embed should appear in the editor immediately. Congrats, you now have testimonials dispayed on your site driving sales!