How can an Opt-out be set up for Mapp Intelligence tracking?
    • 1 Minute to read
    • Dark
      Light

    How can an Opt-out be set up for Mapp Intelligence tracking?

    • Dark
      Light

    Article summary

    You have to integrate an opt-out option for Mapp Intelligence tracking on your website.

    We recommend a double approach for the opt-out with client and server cookies. The client cookie is set by a function call with onclick. The server cookie is obtained by redirecting the track domain. So you are virtually doubly protected.

    You need to add the opt-out based on your chosen tracking integration method. Please see the examples below for a guide.

    Smart Pixel

    <script type="text/javascript">
    	function wtOptOut() {
    		window.wtSmart = window.wtSmart || [];
    		window.wtSmart.push(function(wtSmart) {
    			wtSmart.utils.optout.set(10*12*30*24*60);
    		});
    	}
    </script>
    <a id="optout"
       title="OptOut click" 
       href=https://[TrackDomain]/[TrackId]/optout.php?redirect=[encoded URL of data privacy page]
       onclick="wtOptOut();"
    >Click here to opt-out from tracking</a>

    Note, that you have to replace the following elements in the link:

    • TrackDomain

    • TrackId

    • encoded URL of data privacy page

    Tag Integration

    <script type="text/javascript">
    	window.wts = window.wts || [];
    	if (typeof window.wts.get === 'function') {
    		wts.get('setCookie')('webtrekkOptOut', 1, 10*12*30*24*60);
    	}
    </script>
    <a id="optout"
       title="OptOut click" 
       href=https://[TrackDomain]/[TrackId]/optout.php?redirect=[encoded URL of data privacy page]
       onclick="wtOptOut();"
    >Click here to opt-out from tracking</a>

    Note, that you have to replace the following elements in the link:

    • TrackDomain

    • TrackId

    • encoded URL of data privacy page

    Pixel without Tag Integration (v4)

    <script type="text/javascript">
    	function wtOptOut() {
    		if (typeof window.wt.setCookie === 'function') {
    			window.wt.setCookie('webtrekkOptOut', 1, 10*12*30*24*60);
    		}
    	}
    </script>
    <a id="optout"
       title="OptOut click" 
       href=https://[TrackDomain]/[TrackId]/optout.php?redirect=[encoded URL of data privacy page]
       onclick="wtOptOut();"
    >Click here to opt-out from tracking</a>

    Note, that you have to replace the following elements in the link:

    • TrackDomain

    • TrackId

    • encoded URL of data privacy page


    Was this article helpful?