Website Tracking Engine Guide

Website AI embed (separate from drip)

For AI chat on public sites without email tracking, use the workspace Website AI page. It loads assets/js/ai_site_embed.js and data-ai-site-public-key on <body>. Events and IP-based reporting go to ai_site_public_api.php — not drip_engagement.php.

LLM grounding reuses the same project LLM Content (prompts + crawl) as the rest of the workspace.

1) Page Tracking Code (Where to place)

Step 1: Paste the script once so it loads on all pages (head with defer or before closing body).

code


		

Step 2: Put page-view / dwell attributes on the opening <body> tag.
Do not paste <body ...> at the bottom.

<body data-drip-boot-event="pageview" data-drip-boot-action="viewed">
  ... page content ...
</body>

2) Event Key Details

Action Event Key Trigger action Example markup
Page viewed pageview viewed <body data-drip-boot-event="pageview" data-drip-boot-action="viewed">
Page stay (dwell) page_stay viewed <body data-drip-dwell-event="page_stay" data-drip-dwell-action="viewed" data-drip-engage-ms="15000">
Use milliseconds in code: 15 sec = 15000, 1 min = 60000, 1 hr = 3600000.
Button click button_click clicked <a href="360Degree-process" class="process-hero-cta" data-drip-event="button_click" data-drip-trigger-url="360Degree-process"></a>
Form submit form_submit submitted <form data-drip-event="form_submit" data-drip-trigger-url="contact">...</form>
Form filling form_filling custom <input type="text" data-drip-fill-event="form_filling" />

3) FAQ

Q: Do I paste all snippets on every page?
A: No. Keep script globally. Add only relevant snippet markup where needed (button on button pages, form on form pages).

Q: Where should script go?
A: In <head> with defer (recommended) or just before </body>.

Q: Where should body tracking attributes go?
A: On the opening <body> tag only.

Q: Why event_key + trigger_action both?
A: Event key identifies the behavior; trigger action identifies the type (viewed/clicked/submitted/custom). Both must match dashboard rule.

Q: Can I use custom names?
A: Yes, but keep lowercase with letters, numbers, underscore or hyphen.

3.1) Dwell Time Checker (sec/min/hrs)

This auto-converts to milliseconds for data-drip-engage-ms.

	

4) Expand For Full Details

6) Dashboard mapping
7) Website engagement snippets

Use the snippets on each engagement template in the mailer dashboard, or copy the defaults below:


		

		

		

		

	
8) Ready-to-use for your 360 page

Use these exact changes in your 360Degree-service style pages:

A) Opening body tag (page view)

<body data-drip-boot-event="pageview" data-drip-boot-action="viewed">

B) "Check Process" button (click tracking)

<a href="360Degree-process"
   class="process-hero-cta"
   data-drip-event="button_click"
   data-drip-trigger-url="360Degree-process">
   Check Process
</a>

C) Popup form (submit tracking)

<form data-drip-event="form_submit" data-drip-trigger-url="contact">
  ...
</form>

D) Popup form fields (form filling tracking)

<input type="text" placeholder="Name *" required data-drip-fill-event="form_filling" />
<input type="tel" placeholder="Phone*" required data-drip-fill-event="form_filling" />
<input type="email" placeholder="Email*" required data-drip-fill-event="form_filling" />
<input type="text" placeholder="Location*" required data-drip-fill-event="form_filling" />
<input type="text" placeholder="Company*" required data-drip-fill-event="form_filling" />

E) Footer scripts and closing tags

<script src="YOUR_TRACKING_SCRIPT_URL" defer></script>
<script src="sub-servicepage.js" defer></script>
</body>
</html>
Important: Keep only one closing </body> tag (not two).