Excluding Querystrings from being rewritten

Overview

The default behavior on DNN is for query strings to be turned into part of the URL unless specified. Therefore, if a user visits the site with a tracking link, DNN will rewrite this URL automatically through the Advanced URL Manager. This may skew analytics data as this will be interpreted as a different page for Analytics services.

 

Prerequisites

 

Solution

The solution is to add all of the query strings used for tracking such as gclid and fbclid to the list of 'Keep in Querystring Regex'.

  1. Go to Settings > SEO > Url Management > Expressions, and append the specific query string to the Keep in Querystring Regex text box.

    2020-09-22_11_57_37-My_Website___Home.png

    For example:

    /nomo/\d+|/runningDefault/[^/]+|/popup/(?:true|false)|/(?:page|category|sort|tags)/[^/]+|tou/[^/]+|(/utm[^/]+/[^/]+)+|/gclid/|/fbclid/
  2. Click Save.

Testing

You can test that the query strings are not being rewritten by AUM by accessing the URL with the query strings. If a user visits the site with a tracking link (e.g. mysite.com/sales?glid=randomstring), DNN should not rewrite this URL to mysite.com/sales/glid/randomstring.

Comments

0 comments

Article is closed for comments.