mhe / silverstripe-matomo
There is no license information available for the latest version (v2.0.0) of this package.
Silverstripe module to include Matomo analytics tool
Package info
github.com/martinheise/silverstripe-matomo
Type:silverstripe-vendormodule
pkg:composer/mhe/silverstripe-matomo
v2.0.0
2025-11-12 15:43 UTC
Requires
- php: ^8.3
- silverstripe/recipe-cms: ^6.0
Requires (Dev)
- phpunit/phpunit: ^11.3
- squizlabs/php_codesniffer: ^3.7
This package is auto-updated.
Last update: 2026-03-12 16:31:43 UTC
README
Add support for Matomo analytics tool to a Silverstripe installation.
- The specific setup is done via SiteConfig
- logged in backend users are excluded from tracking (configurable)
- insert opt-out code into template or simply into page content via shortcode
- opt-out supports inlined form/JavaScript (default) or Matomo-standard iframe
Requirements
Requires Silverstripe 6.x – for a version compatible with Silverstripe 5 see respective branch 5
Configuration
Options in CMS Settings (SiteConfig, Tab Matomo):
- Activate tracking
- Tracking URL (URL of Matomo installation)
- Site ID
Developer configuration (YAML)
- Mhe\Matomo\Extensions\MatomoConfig.track_cms_users: Track CMS users (with permission CMS_ACCESS_CMSMain) (default: false)
- Mhe\Matomo\Extensions\MatomoConfig.auto_add_tracking_head: add the tracking code to HTML head part – no modifications of the page template(s) needed (default: true)
- Mhe\Matomo\Extensions\MatomoConfig.optout: configuration of opt-out code, array with sub properties:
- method, either 'script' (default) or 'iframe'
Customizable templates
- MatomoOptOutIframe
- MatomoOptOutScript
- MatomoTrackingCodeBody
- MatomoTrackingCodeHead