Setting Up the Ptengine Tracking Code for Shoplaza

Setting Up the Ptengine Tracking Code for Shoplaza #

Follow these steps to install the Ptengine tracking code on your Shoplaza
store for accurate visitor tracking and insights.

Add the Tracking Code to Your Theme #

To install the Basic Code, you need to add it to your Shoplaza theme file.

Steps to Add the Code:

  1. In your Shoplaza Admin Panel, go to Online Store > Themes.
  2. Click Customize button to enter editor page.
  3. Click the ··· over the upper left and choose > Edit code
  4. Find and open the theme.liquid file.
  5. Paste the Ptengine Basic Code inside the <head> section.

Tip: Make sure to place XXXXX (specific code placement instruction goes here) in the correct spot to ensure accurate tracking.


<!-- Ptengine Tag -->
<script src="https://js.ptengine.com/xxxxx.js"></script>
<!-- End Ptengine Tag -->

Setting Up Personalized User Tracking #

What Does the Identify Code Do?

The Identify Code helps recognize and track users, turning anonymous visitors into identified users. This allows you to:

  1. Track individual users across sessions for better insights.
  2. Collect key user details, such as:
    • Last Active Date
    • Registration Date
    • Total Sessions
    • Referring Domain on First Visit
    • Source URL on First Visit
  3. Create detailed user profiles for personalized content and marketing.

Where to Place the Identify Code

We recommend adding the Identify Code on pages where users log in, sign up, or enter personal details, such as:

  • Login Page
  • Registration Page
  • Membership Signup Page

When a user logs in or registers, Ptengine links their information to their device, making it possible to track individual behavior and optimize their experience.

How the Identify Code Works

Example Code:

<script>
document.getElementById('btnSignup').addEventListener('click', function() {
ptengine.identify(document.getEleme
ntById('uid').value, {
//Get email Data
email : document.getElementById('email').value,
//Get Phone Data
phone : document.getElementById('phone').value,
//Get genger Data
gender: document.getElementById('sex').value,
//Get age Data
age: document.getElementById('age').value,
last_active_date: new Date()
})
});
</script>

This example assigns a unique ID (Uid) to a user and stores key details like name, email, and membership type.

Viewing and Exporting User Data

Once users are identified, Ptengine binds user attributes to their unique ID (Uid). You can:

  • View user data inside the User Module.
  • Export user insights for analysis and marketing campaigns.

Was this article helpful?

  • Yes, great!
  • Not really

Thanks for your feedback.

  Sorry about that. Do you mind sharing how we can improve?

    Write your feedback here...