Do not track crawler, bots etc


#1

Hello.
I use the next track code:

< script type=“text/javascript”>
var _paq = _paq || [];
_paq.push([‘trackPageView’]);
_paq.push([‘enableLinkTracking’]);
_paq.push([‘appendToTrackingUrl’, ‘bots=1’]);
(function() {
var u=“https://mypiwikdomen.fr/”;
_paq.push([‘setTrackerUrl’, u+‘piwik.php’]);
_paq.push([‘setSiteId’, 3]);
var d=document, g=d.createElement(‘script’), s=d.getElementsByTagName(‘script’)[0];
g.type=‘text/javascript’; g.async=true; g.defer=true; g.src=u+‘piwik.js’; >s.parentNode.insertBefore(g,s);
})();

< noscript >< p>< img src=“https://mypiwikdomen.fr/piwik.php?idsite=3&rec=1&bots=1” > > style=“border:0;” alt="" />

But this don’t track bots, crawlers, and if I make request from curl I didn’t view it in piwik.
How I can track it?
P.S. My piwik version is 2.15.0

In piwik doc Does Piwik track visitors without Javascript? Does Piwik track search engine bots or other spider / robots? - Analytics Platform - Matomo describe that if I use bots=1 I can view bots, but it doesn’t work for me. I doesn’t see any bot.


(Stefan Giehl) #2

Bots can only be tracked using log analytics. Using the Javascript tracking pixel excludes most bots and crawlers, as nearly all of them do not load or interpret the script content on the page.