This extension allows easily adding the google analytics tracking code to your forum.
download
You can use composer to install the extension. If you have composer installed globally on your system, connect with ssh (or a console) and run the following command from the flarum installation directory:
composer require hyn/flarum-analytics
If you have a local composer.phar file, use the following command in the flarum installation directory:
php composer.phar require hyn/flarum-analytics
Visit your admin - extensions page afterwards and enable the analytics extension, a popup will be shown to add your UA tracking code. Once entered, the tracking code is automatically added on the forum at the end of the page.
If you want to update the tracking code, just visit the extensions page in your admin and click on the three horizontal dots appearing after hovering over the extension.
Changelog
0.2.1
- Now actually registers a visit to any next page, instead of only the first.
0.2.0
0.1.0
- Easily set tracking codes in admin
- Automatically add tracking javascripts to forum using the tracking information provided in admin
- Support at least google analytics
Roadmap
- Support more trackers: piwik, more?