Google Analytics Integration with Bold360 Layered Windows
Integrate Google Analytics with Layered Chat Windows, track visitor interactions as Analytics events and gain accurate insight into visitor behavior.
As dynamic elements on a website, Layered Chat Windows require a mechanism to cache tracking information and provide accurate results. This step-by-step guide describes a Local Storage implementation that allows data to persist when a chat session is interrupted.
- Visitor navigates to a new page under the same domain.
- Connection dropout occurs.
- Visitor browses multiple pages on the website simultaneously.
- Visitor closes and re-opens or reloads a page.
The Local Storage technology is compatible with the following browsers:
- Google Chrome recommended (Last 20 versions)
- Mozilla Firefox on Windows (Last 10 versions)
- Microsoft Edge
- Microsoft Internet Explorer 9 and newer
- Safari on macOS (Last two versions)
- Opera (Last 10 versions)
See the WebStorage article on Wikipedia for details.
Prerequisites
All pages on your site must either include or reference the following code snippets:
- Bold360 visitor monitoring code
- Google Analytics snippet
Task One: Configure the Chat Frame Javascript Include
Add a Chat Frame Javascript Include to the Chat Window Definition deployed to your site. This code intercepts chat events and passes them to the chat window via the postMessage method.
Task Two: Configure the Chat Window Javascript Include
Add a Chat Window Javascript Include to the Chat Window Definition deployed to your site.
Task Three: Video Chat Events (Optional)
Track video chat events by updating your Chat Frame and Chat Window Javascript Includes.
Tracking messages contain specific video chat events that are assigned to individual Event Categories. This data is appended to _tEvents objects.
Reporting
Events are reported with a few seconds' delay under the Real-Time Events section and they are processed and made available within 24 hours under the Behavior section as well as Dimensions in Custom Reports, allowing maximum flexibility to be tied to any other Google Analytics dimension and metric.

Troubleshooting
For troubleshooting purposes and to ensure that events are transmitted correctly, the code above outputs three log lines for each chat event in the browser console, if available.

Similarly, in case the Google Analytics code is not found by Bold360 on the hosting website page, the following error is thrown in the browser console, if available:
