Skip to content

Commit 775f959

Browse files
author
markzegarelli
authored
Merge pull request #1139 from segmentio/william/LIBWEB-315
[LIBWEB-117] Update VT FAQ with form edge case [DOC-11]
2 parents b7d126f + ce018ec commit 775f959

File tree

1 file changed

+29
-25
lines changed

1 file changed

+29
-25
lines changed

src/connections/sources/visual-tagger.md

Lines changed: 29 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,12 @@
22
title: Visual Tagger
33
---
44

5-
Visual Tagger is a tool that helps you easily collect data about what your customers are doing on your websites without having to write any code. Specifically, it helps you implement `track` events simply by pointing and clicking on parts of your website.
5+
Visual Tagger is a tool that enables you to collect data about what your customers are doing on your websites without having to write any code. Specifically, it helps you implement `track` events by pointing and clicking on parts of your website.
66

77
![Visual Tagger intro](images/vt-docs-1.gif)
88

99
**With Visual Tagger, you can:**
10-
- Create **`track` events** to start collecting data on actions that your users take, such as button or link clicks and form submissions. Events that you create using Visual Tagger work exactly the same way as `track` events that you may have implemented in code. You'll be able to send them to any of the integrations in Segment's Catalog.
10+
- Create **`track` events** to start collecting data on actions that your users take, such as button or link clicks and form submissions. Events that you create using Visual Tagger work the same way as `track` events that you may have implemented in code. You'll be able to send them to any of the integrations in Segment's Catalog.
1111
- Collect rich, contextual information in the form of **properties** to help you understand more about the specific action that the user took.
1212
- **Test your events** to make sure that they are working as expected before you publish them live.
1313

@@ -23,29 +23,29 @@ The Visual Tagger has two main views: the **Visual Tagger Home** and the **Event
2323

2424
Get the following things set up before you use Visual Tagger:
2525

26-
1. **A Segment account and Workspace**. You'll need to have either Workspace Owner or Source Admin-level permissions in order to create events using Visual Tagger.
27-
2. **A website**. Visual Tagger currently works best with simple marketing websites, like landing pages or content sites. There is no support for mobile apps at this time, but you can tag the mobile-web version of your websites using Visual Tagger.
26+
1. **A Segment account and Workspace**. You'll need to have either Workspace Owner or Source Admin-level permissions to create events using Visual Tagger.
27+
2. **A website**. Visual Tagger works best with simple marketing websites, like landing pages or content sites. Visual Tagger does not support mobile apps , but you can tag the mobile-web version of your websites.
2828
> **Note**: Your website must use HTTPS.
2929
3030
3. **A [Javascript (Website) Source](/docs/connections/sources/catalog/libraries/website/javascript/) in Segment**.
3131
Once you create a Javascript Source, you must add the analytics.js snippet to the website for Visual Tagger to work.
3232
If you're having trouble with this step, follow the [Analytics.js Quickstart Guide](/docs/connections/sources/catalog/libraries/website/javascript/quickstart/).
33-
4. **Chrome browser**. Visual Tagger is only supported for Chrome browser at this time.
33+
4. **Chrome browser**. Visual Tagger supports the Chrome browser.
3434

3535
## Enable Visual Tagger
3636

37-
Once you have all of the prerequisites set up, you're ready to get started:
37+
Once you have all the prerequisites set up, you're ready to get started:
3838

3939
1. Go to your Segment Workspace and navigate to your Website Source.
4040
2. Click the **Visual Tagger** tab to go to the Visual Tagger main page.
4141
You'll see an introduction, where you can learn about Visual Tagger and watch a short overview video.
4242
3. If this is your first time on this page, click **Get Started**.
43-
Segment checks that you have the Visual Tagger Chrome extension installed and the correct type of source. If either of these items is missing, follow the instructions to install the extension, and enable the Visual Tagger. Click **Continue**.
44-
4. Visual Tagger asks what type of website you have so it can recommend events to track. You can also choose `Other` and describe your website, to help us prioritize which event types to add next.
43+
Segment checks that you have the Visual Tagger Chrome extension installed and the correct source type. If either of these items is missing, follow the instructions to install the extension, and enable the Visual Tagger. Click **Continue**.
44+
4. Visual Tagger asks for the website type it can recommend events to track. You can also choose `Other` and describe your website, to help Segment prioritize which event types to add next.
4545
![Getting Started Steps](images/vt-docs-website-type.png)
4646
5. The next screen shows **Recommended Events**, and you can choose which ones are relevant to your site. (You can also track any events beyond the recommended ones!)
4747
![Getting Started Steps](images/vt-docs-setup-starterkit.png)
48-
6. The UI then loads a page with your website in an internal frame. Click one of the event type names to select it and begin configuring. We'll go over these [in the following sections](#step-1-choose-the-event-type-and-select-an-element).
48+
6. The UI then loads a page with your website in an internal frame with the option to launch in a popup. Click one of the event type names to select it and begin configuring. For more information about event types and names. see [Step 1](#step-1-choose-the-event-type-and-select-an-element) below.
4949

5050
As you click each event, you're prompted to select the part of the website that should trigger the event, and describe the properties that event should have.
5151
<!-- TODO: this image is outdated
@@ -63,13 +63,13 @@ To create events, start in the **Event Editor** on the **Build** screen. This pa
6363

6464
![Start Drafting Your Event](images/vt-docs-3.png)
6565

66-
You can either choose one of the Recommended Events, or you can click **Add Event** and create a whole new one. Recommended Events works the same way, except that the Event Name is set for you, and each event comes with a set of default properties.
66+
You can either choose one of the Recommended Events, or you can click **Add Event** and create a new one. Recommended Events work the same way, except Segment defines the Event Name, and each event comes with a set of default properties.
6767

6868
When you click **Add Event**, three types of events are available:
6969

70-
- **Button or Link Click**. Select any `button` and `link` elements on the page to create events that fire when a user clicks that button or link. Depending on how your website is built, some elements that look like buttons might not actually be CSS "button" elements - use the "Any Element Click" event instead for these elements.
70+
- **Button or Link Click**. Select any `button` and `link` elements on the page to create events that fire when a user clicks that button or link. Depending on the construction of your website, some elements that look like buttons might not actually be CSS "button" elements - use the "Any Element Click" event instead for these elements.
7171

72-
- **Form Submit**. Select this option to highlight any `form` elements on the page so you can select them. When you choose Form Submit, all form fields are added to your event automatically as **properties**.
72+
- **Form Submit**. Select this option to highlight any `form` elements on the page so you can select them. When you choose Form Submit, Segment adds all form fields to your event automatically as **properties**.
7373

7474
- **Any Element Click**. Selecting this option will allow you to click on any element on your page. This will allow you to create an event for whenever a user on your website clicks on that element.
7575

@@ -92,11 +92,11 @@ When you choose a Recommended Event, it works much in the same way, but the Even
9292
When you click on an element on your website, a window appears where you can enter the details for the event.
9393

9494
1. **Event Name**. Edit the event name to be simple yet descriptive.
95-
Segment recommends that you use an "Object Action" format (for example, `Blog Post Clicked`, and use Title Case (the first letter of each word is capitalized) when naming events.
95+
Segment recommends that you use an "Object Action" format (for example, `Blog Post Clicked`, and use Title Case (capitalize the first letter of each word ) when naming events.
9696

9797
2. **Properties**. Add properties to the event to add contextual information about the action that the user took. Properties are optional, but they are very helpful when you analyze events data later.
98-
- Use `snake_case` for property names (all lowercase, with spaces between words represented as an underscore “_”). For a guide on event naming best practices, check out our Docs [here](https://segment.com/docs/protocols/tracking-plan/best-practices/#formalize-your-naming-and-collection-standards).
99-
- Check the [list of properties that are collected by default](https://segment.com/docs/connections/spec/common/) before you add a property.
98+
- Use `snake_case` for property names (all lowercase, with spaces between words represented as an underscore “_”). For a guide on event naming best practices, check out our Docs [here](docs/protocols/tracking-plan/best-practices/#formalize-your-naming-and-collection-standards).
99+
- Check the [list of properties that are collected by default](/docs/connections/spec/common/) before you add a property.
100100

101101
3. **Advanced**. You can also click the `</>` button to manually edit the CSS selector. If you didn't select the right element, you can choose the element on the page again by clicking on the finger button.
102102

@@ -153,7 +153,7 @@ If something doesn't look right, click **Back** to return to the Build screen an
153153

154154
![Test Your Event](images/vt-docs-6.gif)
155155

156-
If you’re having trouble validating your events, check out our [Troubleshooting Tips](#troubleshooting-your-events).
156+
If you’re having trouble validating your events, see [Troubleshooting Tips](#troubleshooting-your-events).
157157

158158
## Step 4: Publish the event(s)
159159

@@ -172,39 +172,39 @@ In one window, open up your website where you created the event. In another wind
172172
173173
On your website, pretend that you are an end-user and try to trigger the event that you created in Visual Tagger. Watch the Debugger in the other window to confirm that the event fired when you took that action.
174174

175-
All events created using Visual Tagger automatically get a context property that says `"visual_tagger" : true` so that you can easily distinguish between events that you implemented using Visual Tagger and events that you implemented using code.
175+
All events created using Visual Tagger automatically get a context property that says `"visual_tagger" : true` so that you can distinguish between events that you implemented using Visual Tagger and events that you implemented using code.
176176

177177
![Verify in Debugger](images/vt-docs-7.png)
178178

179179
## Managing and editing Visual Tagger events
180180

181-
Once you publish your events, they appear on the **Visual Tagger Home** view in the **All Published Events** table. From here, you can create click **Add Event** to craete new events, and edit or delete existing ones.
181+
Once you publish your events, they appear on the **Visual Tagger Home** view in the **All Published Events** table. From here, you can create click **Add Event** to create new events, and edit or delete existing ones.
182182

183183
![Visual Tagger Home](images/vt-docs-8.png)
184184

185185
## Troubleshooting your events
186186

187187
If your events are not working as expected, try the following steps to troubleshoot the issue.
188188

189-
- Ensure that the Visual Tagger integration is toggled on. You find it in the Settings for your Source.
189+
- Ensure that you toggle Visual Tagger integration on. You find it in the Settings for your Source.
190190

191-
- Ensure that analytics.js is implemented on your website. You can confirm this by visiting your website and watching the Segment Debugger. A `page` call should flow into your Debugger whenever someone visits a page on your website if you have implemented analytics.js. Note that if you have an adblocker enabled when you visit your website, data will not get fired into Segment when you interact with your website.
191+
- Ensure that your website has analytics.js installed and running. You can confirm this by visiting your website and watching the Segment Debugger. A `page` call should flow into your Debugger whenever someone visits a page on your website if you have implemented analytics.js. Note that if you have an ad blocker enabled when you visit your website, data will not get fired into Segment when you interact with your website.
192192

193-
- Confirm that the CSS selector has not changed in any way since you created the event in the Visual Tagger (for example, a button could change locations or be removed entirely). Because Visual Tagger relies on the CSS selector to tie events to user actions, if the CSS selector changes, the event stops sending. If this happens, edit the event in Visual Tagger and update the CSS selector. Segment does not currently have a way to alert you when events you created using Visual Tagger begin to fail.
193+
- Confirm that the CSS selector has not changed in any way since you created the event in the Visual Tagger (for example, a button could change locations or be removed entirely). Because Visual Tagger relies on the CSS selector to tie events to user actions, if the CSS selector changes, the event stops sending. If this happens, edit the event in Visual Tagger and update the CSS selector. Segment does not have a way to alert you when events you created using Visual Tagger begin to fail.
194194

195-
- Because Visual Tagger relies on stable CSS selectors to fire events from, it is currently not compatible with websites that have CSS selectors that are dynamically generated on every page load.
195+
- Because Visual Tagger relies on stable CSS selectors to fire events, it is not compatible with websites that have CSS selectors that are dynamically generated on every page load.
196196

197-
- If your website has any iframed components (for example, if you embed Typeforms into your site), Visual Tagger cannot create events for that iframed content. We recommend that you install Segment on the iframed-in site and use Visual Tagger directly on that site.
197+
- If your website has any components in iframes (for example, if you embed Typeforms into your site), Visual Tagger cannot create events for those components. Segment recommends that you install analytics.js on the iframed-in site and use Visual Tagger directly on that site.
198198

199-
- If you use the same name for multiple events (whether in code or using Visual Tagger), duplicate events are *not* created downstream. Instead, those multiple events are joined into one event.
199+
- If you use the same name for multiple events (whether in code or using Visual Tagger), duplicate events are *not* created downstream. Instead, Segment merges those events into one event.
200200

201201
If your events still don't work as expected, contact [Segment Customer Support](https://segment.com/help/contact/) for help.
202202

203203
## FAQs
204204

205205
### Are there situations where Visual Tagger will not work?
206206

207-
Yes! Visual Tagger relies on CSS selectors, which usually involves what is called "class names" such as "hero" or "footer". Some web technologies automatically generate these names and change them on a regular basis, which makes the Visual Tagger events stop firing.
207+
Yes! Visual Tagger relies on CSS selectors, which involves "class names" such as "hero" or "footer". Some web technologies automatically generate these names and change them on a regular basis, which makes the Visual Tagger events stop firing.
208208

209209
Squarespace uses this technique, and you can examine the HTML of your site to see if the "class names" are randomized letters/numbers.
210210

@@ -260,6 +260,10 @@ However, adding a large number of tags to your site could potentially impact you
260260

261261
Yes. You can track dynamically generated elements like modals (for example) using the Visual Tagger.
262262

263+
### Why does my form submit event not work?
264+
265+
Visual Tagger binds its event listeners to the `document` object. Forms using `stopPropagation` and `stopImmediatePropagation` methods prevent the event from bubbling up, causing Visual Tagger to not execute the handlers for emitting track/identify calls. Remove any `stopPropagation` and `stopImmediatePropagation` method calls from your form handler to allow Visual Tagger to process the event.
266+
263267
### Does Visual Tagger have a data layer so that I can make use of data that's not rendered on the page?
264268

265269
Currently, only information that is visually present on the page is available for use in the Visual Tagger.

0 commit comments

Comments
 (0)