Replace single tracking code with WP-Matomo Integration plugin on mullti-site

We have a Wordpress multi-site installation. We are running Matono on premise.
So far we tracked by inserting the JS-tracking code in the theme header. This worked, only wie could not track the individual sites.
I took over from a former admin and was charged with installing the WP-Matomo Integration plugin. I installed the plugin thinking it would remove or replace any superfluous codes. The widget appeared in the dashbard of each separate site, but it was the same for all and seemd to be tracking the whole site as before. Consequentyl I removed the JS tracking code in the theme header. This changed nothing. I deactivated the plugin, but somehow Matomo keeps tracking. I cannot say if the numbers it shows are realistic. They seem to be low, but we have strong fluctuation anyway.
Could there be a third tracking mode that I cannot find? I think before trying to get the plugin running Ishould remove everything else, shouldn’t I?

Thanks
Martin

Hi @martinauer

thank you to join the Matomo community team and sorry to hear that you encounter some strange behaviors.
The wordpress plugin installation won’t remove any of the previously added tracking code: you have to do it manually.
In a network mode, data displayed in the widgets that you can add in your dashboards are per store, not globally.
When you say that it change nothing after you remove the JS code from the theme header, you means that you continue to get some data in the Matomo available from Matomo Analytics > Reporting menu? It’s normal. Removing the JS code from the headers remove the Matomo on premise JS code. If you want to stop tracking your visitor, you must disable the tracking from the Matomo analytics > settings menu in the network context.
If you deactivate the plugin and you still have some tracking data, maybe you have a page cache plugin which kept the page content in cache.
Would you mind sharing with us the content of your system reports available from the menu Matomo Analytics > Diagnostics to try to reproduce the problem?
Kind regards

Matthieu

Hi Matthieu,

thank you for your answer.

Maybe the reason for the unwanted behavior is that I installed the WP-Matomo Integration plugin without removing the js tracking code. I only removed the tracking code later. Then I also deactivated and deleted the plugin. Since I deactivated the plugin the numbers slowly petered out from 1890 visits on July 26 to 40 visits on August 1. Maybe this is because some returning users have the javascript cached in their browsers?

Anyway, today I reinstalled and activated the plugin. On the settings page it says:
WP-Matomo 1.0.25 is successfully connected to Matomo 4.3.1. You are running a WordPress 5.8 blog network (WPMU). WP-Matomo will handle your sites as different websites.

But in the dashboard of each site the widget shows the same numbers (last 30 days):
Besucher: 22733 etc.

Should I change some settings on the Matomo analytics page? The plugin instructions don’t say anything about this.

I attach today’s system check:

Click to view System Check

Mandatory checks

PHP-Version >= 7.2.5:

:heavy_check_mark: 7.4.9

PDO Erweiterung:

:heavy_check_mark:

PDO\MYSQL Erweiterung:

:heavy_check_mark:

MYSQLI Erweiterung:

:heavy_check_mark:

Weitere erforderliche Anforderungen:

:heavy_check_mark: zlib :heavy_check_mark: SPL :heavy_check_mark: iconv :heavy_check_mark: json :heavy_check_mark: mbstring :heavy_check_mark: Reflection :heavy_check_mark: filter :heavy_check_mark: hash :heavy_check_mark: session

Erforderliche Funktionen:

:heavy_check_mark: debug_backtrace :heavy_check_mark: eval :heavy_check_mark: hash :heavy_check_mark: gzcompress :heavy_check_mark: gzuncompress :heavy_check_mark: pack

Benötigte PHP Konfiguration (php.ini):

:heavy_check_mark: session.auto_start = 0 :heavy_check_mark: max_execution_time = 0 OR >= 30

Verzeichnisse mit Schreibzugriff:

:heavy_check_mark: $DOC_ROOT/tmp :heavy_check_mark: $DOC_ROOT/tmp/assets :heavy_check_mark: $DOC_ROOT/tmp/cache :heavy_check_mark: $DOC_ROOT/tmp/climulti :heavy_check_mark: $DOC_ROOT/tmp/latest :heavy_check_mark: $DOC_ROOT/tmp/logs :heavy_check_mark: $DOC_ROOT/tmp/sessions :heavy_check_mark: $DOC_ROOT/tmp/tcpdf :heavy_check_mark: $DOC_ROOT/tmp/templates_c

Optional checks

Private Verzeichnisse benötigt:

:heavy_check_mark: Alle privaten Verzeichnisse sind aus dem Internet nicht zugänglich.

Dateiintegrität:

:heavy_check_mark:

Tracker-Status:

:heavy_check_mark:

Speicherlimit:

:heavy_check_mark: 256M

Zeitzone:

:heavy_check_mark:

Öffnen einer URL:

:heavy_check_mark: curl

PageSpeed deaktiviert:

:heavy_check_mark:

GD > 2.x + Freetype (graphics):

:heavy_check_mark:

Andere Erweiterungen:

:heavy_check_mark: json :heavy_check_mark: libxml :heavy_check_mark: dom :heavy_check_mark: SimpleXML :heavy_check_mark: openssl

Andere Funktionen:

:heavy_check_mark: shell_exec :heavy_check_mark: set_time_limit :heavy_check_mark: mail :heavy_check_mark: parse_ini_file :heavy_check_mark: glob :heavy_check_mark: gzopen :heavy_check_mark: md5_file

Dateisystem:

:heavy_check_mark:

Cron einrichten (schneller ladende Berichte):

:warning: Warning: Für eine optimale Leistung und ein schnelles Matomo wird dringend empfohlen, einen Crontab einzurichten, um Ihre Berichte automatisch zu archivieren und das Auslösen durch den Browser in den Matomo-Einstellungen zu deaktivieren. Erfahren Sie mehr.

Cron einrichten - Prozesse via CLI steuern:

:heavy_check_mark: OK

Datenbankfähigkeiten:

:warning: Warning: UTF8mb4 charset

Ihre Datenbank unterstützt den utf8mb4 Zeichensatz, aber Ihre Datenbanktabellen wurden noch nicht konvertiert. Sie können dies nachholen, indem Sie den Befehl $DOC_ROOT/console core:convert-to-utf8mb4 ausführen oder die automatische Konvertierung in den generellen Einstellungen aktivieren.

Dies ist nötig, um 4-Byte UTF8 Zeichen speichern zu können. Wenn utf8mb4 nicht verfügbar ist, werden spezielle Zeichen wie Emojis, selten verwendete Zeichen asiatischer Sprachen, historische Schriftzeichen oder mathematische Symbole mit � ersetzt. Sie können mehr über dieses Thema in diesen FAQ lesen.
:heavy_check_mark: LOAD DATA INFILE :heavy_check_mark: CREATE TEMPORARY TABLES :heavy_check_mark: Changing transaction isolation level

Maximale Packetgröße:

:heavy_check_mark:

Erzwungene SSL Verbindung:

:heavy_check_mark:

Standorterkennung:

:warning: Warning: Die voreingestellte Standorterkennung versucht das Herkunftsland des Besuchers anhand dessen verwendeter Sprache zu erkennen. Dies ist nicht sehr genau, daher wird empfohlen Geolocation-Datenbank zu installieren und zu nutzen.

Update über HTTPS:

:heavy_check_mark:

Schreibbarer JavaScript-Tracker ("/matomo.js"):

:heavy_check_mark:

Informational results

Matomo Version:

4.3.1

Matomo Update History:

4.2.1,3.14.0,

Matomo Install Version:

3.14.0

Latest Available Version:

4.4.1

Is Git Deployment:

0

PHP_OS:

Linux

PHP_BINARY:

/opt/php7.4/sbin/php-fpm

PHP SAPI:

fpm-fcgi

Timezone Version:

2020.1

PHP Timezone:

UTC

PHP Time:

1627902961

PHP Datetime:

2021-08-02 11:16:01

PHP INI max_execution_time:

60

PHP INI post_max_size:

64M

PHP INI max_input_vars:

10000

PHP INI zlib.output_compression:

0

Curl Version:

7.47.0, OpenSSL/1.0.2g

Suhosin Installed:

0

DB Prefix:

matomo_

DB Charset:

utf8

DB Adapter:

PDO\MYSQL

MySQL Version:

5.7.33-0ubuntu0.16.04.1

Num Tables:

60

Browser Segment Archiving Enabled:

1

Development Mode Enabled:

0

Internet Enabled:

1

Multi Server Environment:

0

Auto Update Enabled:

1

Custom User Path:

0

Custom Include Path:

0

Release Channel:

latest_stable

Plugins Activated:

API, Actions, Annotations, BulkTracking, Contents, CoreAdminHome, CoreConsole, CoreHome, CorePluginsAdmin, CoreUpdater, CoreVisualizations, CustomDimensions, CustomJsTracker, Dashboard, DevicePlugins, DevicesDetection, Diagnostics, Ecommerce, Events, Feedback, GeoIp2, Goals, Heartbeat, ImageGraph, Insights, Installation, Intl, IntranetMeasurable, LanguagesManager, Live, Login, Marketplace, MobileMessaging, Monolog, Morpheus, MultiSites, Overlay, PagePerformance, PrivacyManager, ProfessionalServices, Proxy, Referrers, Resolution, RssWidget, SEO, ScheduledReports, SegmentEditor, SitesManager, Tour, Transitions, TwoFactorAuth, UserCountry, UserCountryMap, UserId, UserLanguage, UsersManager, VisitFrequency, VisitTime, VisitorInterest, VisitsSummary, WebsiteMeasurable, Widgetize

Plugins Deactivated:

CustomVariables, DBStats, MobileAppMeasurable, Provider, TagManager

Plugins Invalid:

Server Info:

Apache

Had visits in last 1 day:

1

Had visits in last 3 days:

1

Had visits in last 5 days:

1

Archive Time Last Started:

0

Archive Time Last Finished:

0

User Agent:

Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.164 Safari/537.36

Browser Language:

de,en-us,en,fr

Total Invalidation Count:

340

In Progress Invalidation Count:

0

Scheduled Invalidation Count:

340

Earliest invalidation ts_started:

Latest invalidation ts_started:

Earliest invalidation ts_invalidated:

2021-05-11 00:51:15

Latest invalidation ts_invalidated:

2021-08-02 02:30:17

Number of segment invalidations:

0

Number of plugin invalidations:

0

List of plugins being invalidated:

Anonymize Referrer:

Do Not Track enabled:

1

Thanks
Martin

Hi @martinauer

thanks for your answer.
I understand better: you are using the plugin https://wordpress.org/plugins/wp-piwik/#description not our own one https://wordpress.org/plugins/matomo/ ?
As this plugin does not belong to us, I can’t provide any support on it.
Maybe you can ask your question on their forum? https://wordpress.org/support/plugin/wp-piwik/
Kind regards

Matthieu