Workspace scripts

What are workspace scripts?

This section of the application allows you to add code snippets that you want to apply to multiple pages in the workspace at the same time. To learn more about settings that affect an account versus settings that affect a workspace, please refer to this guide:

You can add any HTML, CSS, or Javascript codes that you want to be applied to multiple pages at once, including but not limited to: a consent management banner, the Google tag of a Google Analytics property, the Google tag of your Google Tag Manager container, an HTML FAQ widget, CSS to change the properties of a specific class of objects, a sticky header code, various kinds of tracking scripts from your desired tracking platforms, etc.
It is up to you what you choose to add in this section, depending on your goals for your landing pages.

You can choose to add the scripts to all past and future pages at once or to manually enable which pages they should be on. These options are explained in more detail below.

NOTE: This feature is only available for some of our subscriptions. If that is the case, you will see an upgrade prompt when attempting to access it. More information about our currently available subscriptions can be found here: 

How do I use workspace scripts?

In order to add, edit or remove workspace scripts, click on Assets in the left-side menu, then click on Scripts.

workspace scripts.png

You can add Javascript, HTML, and CSS in all three sections: Head, Body, Footer.
It should always have valid syntax - <script></script> tags for Javascript, <style></style> for CSS, valid HTML syntax.

As long as the syntax is correct, the editor will dynamically change the colors of the text to help you visualize the different components. If the syntax is incorrect, the text will be black. You can use this to look for missing semicolons, accolades, tags, and so on.

Make sure you hit APPLY in order for the changes to be applied before navigating away from this part of the application. 

NOTE: The global scripts added to the whole workspace must be tailored to work for the Thor rendering engine. Click here: to learn more.

Selecting how the scripts placed in this section will be applied to the pages / experiences in the workspace

Above the code editor, you can see these options:


You can select either A, B, or B+C.

A - The scripts will be applied to all the past and future pages inside the current workspace, without the ability to deselect individual pages.

B without C - The scripts will not be automatically applied to any pages. A toggle within the Scripts & Privacy section of each landing page will allow you to turn the script ON.

B and C - The scripts will be automatically applied to all the past and future pages inside the workspace. A toggle within the Scripts & Privacy section of each landing page will allow you to turn the script OFF.

Where can I manually enable or disable the global script for a single landing page?

In the Landing Pages tab, click on the name of the desired page, then click on Script & Privacy. Scroll to the bottom and you will see this.



If you chose option A from above, Enable the script for all pages, then the toggle will be greyed out.

Which scripts will load first on a page?

The workspace scripts will load on the live URL of a page first, then the ones placed inside the builder or in the slideout will. They do work together, so the function of a workspace script can be enriched by a page-level script if they are written to do that.