Kentico Xperience 13 documentation and ASP.NET Core

Most documentation about running Xperience applications under ASP.NET Core can be found in a dedicated section: Developing Xperience applications using ASP.NET Core. The rest of the documentation still applies, but some code samples and scenarios might need slight modifications for Core projects.

All major differences between the MVC 5 and Core platforms are summarized in Migrating to ASP.NET Core.

×

Enabling activity tracking

Activities represent actions that your contacts perform. For example, the system logs activities when visitors register as a member of a site or when visitors sign in to a site. The data gathered in the activity log allows you to evaluate the behavior of your website's users and visitors. To learn more about activities, see Tracking contact activities.

To allow tracking of activities for contacts, you need to:

  1. Open the Settings application.
  2. Navigate to On-line marketing and ensure that the Enable on-line marketing setting is selected for your website.
  3. Switch to the On-line marketing -> Contact management -> Activities category:
    • Enable the Log activities setting.
    • Configure logging of specific activity types using the other settings in the category.
    • Enable or disable the Log activities based on legitimate interest setting (see the section below for more information).
  4. Save the settings.

Some activities are logged automatically when you enable tracking of contacts. However, certain activities require additional adjustments of your live site (MVC) application.

Logging activities based on legitimate interest

Most activities are only logged for visitors who give consent to be tracked as contacts and have the required cookie level set (Visitor or All). However, enabling the Log activities based on legitimate interest setting allows the system to log On-line form submission activities even for visitors who have not given tracking consent.

On this page

Enterprise license required

Features described on this page require the Kentico Xperience Enterprise license.

Data added into the system as a result of such activities only includes information explicitly entered into the form. When an untracked visitor submits a form, the system creates a new contact with data based on the form's mapping of fields to contact attributes. If the form contains an email address field and the submitted email matches an existing contact, the data is instead added or updated for the given contact. This type of activity logging does not enable any other type of tracking for the visitor.

Additionally, the system removes any UTM parameters from the URL values logged for such activities (utm_campaign, utm_source, etc.).

Important

You need to ensure that usage of personal data collected through such activities falls under legitimate interest purposes, based on your site's legal requirements. For example, you may be able to legally use the activities as triggers for automation processes, such as advanced form responders. However, using the data to send unsolicited marketing messages may be a breach of data protection regulations.

Overview of activities

E-commerce
Product added to shopping cartLogged automatically.
Product added to wishlistMust be logged manually.

Product removed from shopping cart

Logged automatically.
PurchaseLogged automatically.

Purchased product

Logged automatically.
Shopping cart abandonedLogged automatically.
Email marketing

Clicked link in marketing email

Logged automatically.

Opened marketing email

Logged automatically.

Subscription to a newsletter

Logged automatically.
Unsubscription from a single email feedLogged automatically.

Opted out from all marketing emails

Logged automatically.
Membership
User loginMust be logged manually.
User registrationMust be logged manually.
Other

Form submission

Logged automatically.
Custom table form submitLogged automatically.
Page
Landing pageLogged after adjusting your live site application.
Page visitLogged after adjusting your live site application.
Search
External searchLogged after adjusting your live site application.
Internal searchMust be logged manually.

For more information about logging of activities that require additional adjustments of your live site (MVC) application, see Logging activities.

  • To log the Landing page, Page visit, and External search activities, you need to explicitly enable the activity tracking feature for your live site application (which registers routes that receive logging requests).

    The Landing page activity logging is affected by the CMSLandingPageLoaded cookie key, which expires after 20 minutes. The expiration period of the key is renewed every time the website is accessed again.

  • To log the User login, User registration, Product added to wishlist and Internal search activities, you need to manually call a logging service in your own controllers.

Disabling activity logging for users

By default, the system tracks activities for all contacts. You can disable activity tracking for the user accounts of registered users.

  1. Open the Users application.
  2. Find and edit the given user account.
  3. Switch to the Settings tab.
  4. Disable the Log activities property.
  5. Click Save.

The activities performed by the registered user will no longer be recorded.

Configuring activity and contact update processing

The API does not ensure recalculation of contact scores, contact groups, personas and marketing automation triggers when logging activities from the live site application. For performance reasons, these recalculations are performed by the Xperience application.

Important

Because the Xperience application itself does not usually receive traffic from site visitors, you need to keep the application alive. For example, you can set the Start Mode advanced setting of the used application pool in IIS to AlwaysRunning.

By default, the system batch processes activities and contact detail updates every 10 seconds. You can configure the processing interval separately for the Xperience and live site application. Adding the below key to the live site application affects the interval at which logged activities and contact detail updates are saved from the memory into the database. Adding the below key to the Xperience application affects how often Xperience recalculates the data that could be affected by activities and contact updates.

If your system processes a large number of activities and contact updates, you may need to increase the default interval.

  1. Open your project's web.config file.
  2. Add the following key into the appSettings section of the file. Increase the value to reflect how often you want the activities and contact updates to be processed.

    Processing activities and contact updates every 30 seconds
    <add key="CMSProcessContactActionsInterval" value="30" />
  3. Save the file.

The system now processes activities and contact detail updates in accordance with the configured intervals.


Was this page helpful?