Logging Custom Website Activities

The LeadSquared Web Tracking feature by default tracks web activities such as website visits and form submissions through its tracking script. You can also track custom web events such as button clicks, image clicks or video views. This will enable you to track your prospect action beyond page views and submissions, since there may be more important activities that help you learn more about your prospects.

 

Prerequisites

  1. To use this feature, you need to have basic JavaScript skills.
  2. Please ensure that LeadSquared tracking script is installed on all the pages where you need to use this feature.
  3. You’ll need two additional pieces of information- Your Account Number and theĀ Activity Code for the activity.

 

Procedure

Once you have the Account number and Event Code, you just have to add the following JavaScript code on the respective event you would like to capture.

logMXWebEvent('Account Number','Activity Code','Description','score');

‘Description’ and ‘Score’ are optional parameters, you can pass them only if required.

  • In our example above, assuming account number is 1, we would call:
    logMXWebEvent(1, 154,'Home Page Main CTA', 5);
  • If I don’t need to pass description and custom score, I would call:
    logMXWebEvent(1, 154);

This function would be called inside the event handler you want to capture. You would see the leads’ events in the activity history when logged:

Logging custom activities

 

Any Questions?

If you encountered any errors while following the procedure listed here, or if you have any other related questions, go ahead and enter them in the comments section below.

Subscribe
Notify of
guest
4 Comments
Newest
Oldest Most Voted
Inline Feedbacks
View all comments
shivam
5 months ago

how can i add this code in a wordpress website on buttons

Oshin Anand
Admin
Reply to  shivam
5 months ago

Hi Shivam.
1. Deploy the LeadSquared Tracking Script on your website.
2. Call the code given in the Logging Custom Website Activities help article with on click attribute.
If you have further questions, reach out to support@leadsquared.com.

Shikhar Deep
Shikhar Deep
1 year ago

is this is a depreciated feature?

Dharshana Santhanam
Reply to  Shikhar Deep
1 year ago

Hello, Shikhar.
No, this feature is still available in LeadSquared.