@tsteur opened this Issue on November 26th 2020 Member

Not sure into which plugin to put this best. However, it needs to be disabled by WhiteLabel (eg through some event).

We'd basically show a block in the bottom similar to on our demo.matomo.cloud (might need to go incognito to see it)

(be great to give the social icons some white background or something so they stand out)
"Refer Matomo" is basically a "mailto" link that add's following subject:


Why I no longer use Google Analytics

message body:

Did you know Google uses data for “own purposes”? That means Google owns your data and is using it to monetise their advertising platforms.

This is why I don’t use Google Analytics for analysing the performance of my website. 

Instead I choose Matomo, an ethical alternative to Google Analytics that gives me 100% data ownership and protects the data of my website visitors. 

I’m sharing this message in the hope that you too will take back the power from Google and get complete ownership of your own data.

[Check out Matomo](https://matomo.org/google-owns-your-data?pk_campaign=refer&pk_kwd=onpremise)

The user can then customise the email in their email program and enter email addresses etc.

For social sharing we would use this text if possible:

Did you know Google is using your data for “own purposes”? This means Google owns your data and uses it to monetise their advertising platforms.

If you’re using Google Analytics, stay in control by switching to an ethical alternative like Matomo now! 


can we have buttons for twitter, facebook, linkedin and mastodon? We would not actually load their JS etc but use the share links like https://www.facebook.com/sharer.php and https://twitter.com/intent/tweet and https://www.linkedin.com/shareArticle/ . Not sure it's possible for mastodon?

After clicking on any of the links and the desired action was initiated could we maybe show a thank you modal dialog saying like Thank you for spreading the word and creating a safer web?

  • When someone clicks on the X icon on the right then we don't show it for another 6 months.
  • Let's maybe in the beginning also only show it to super users (end users are often not that passionate about this topic)
  • Once someone clicked on "refer matomo" or on the social media links we don't show it again for now
@flamisz commented on February 18th 2021 Contributor

@tsteur I have a question about this. I have a solution where I store the events (when it was closed, it was shared or not, etc) in the browser's localstorage. For sure it's not the perfect solution, if a user changing browsers or using incognito mode it won't work.

Do you have any other recommendation? Like storing for the user in db?


@tsteur commented on February 18th 2021 Member

Hi @flamisz

be great to store this in the backend instead of in the browser so it won't appear every time they go incognito etc.

I was going to suggest we use the UsersManager.setUserPreference API see https://github.com/matomo-org/matomo/blob/4.1.0/plugins/UsersManager/API.php#L194 but it's not really a preference so better not to use it.

There is a plugin_settings table which can store plugin related settings for each user (see example usage here https://github.com/matomo-org/matomo/blob/4.1.0/plugins/CorePluginsAdmin/Model/TagManagerTeaser.php#L44-L58 where it was used for a similar feature) but it's kind of the same thing... it's not really a setting and this backend was basically built for this feature https://developer.matomo.org/guides/plugin-settings and we'd probably end up using the API not quite in the intended way.

I would actually for now simply store it in the option table similar to https://github.com/matomo-org/matomo/blob/4.1.0/plugins/Feedback/Feedback.php#L80-L93 and https://github.com/matomo-org/matomo/blob/4.1.0/plugins/Feedback/Controller.php#L37-L47

Compared to this example where it also uses the Option class it be great though to put the logic for setting and getting this value into a separate class like Piwik\Plugins\Feedback\ReviewReminder. When developing the linked FeedbackReminder logic above should have also put it in a separate class.

Does this help? I think that feedback reminder is quite a similar logic where we'd also need a controller method to update the value etc. It might help to check how the logic for that updateFeedbackReminderDate controller method works. Let me know if some information is missing

@tsteur commented on February 18th 2021 Member
@flamisz commented on February 18th 2021 Contributor

Thanks @tsteur very helpful indeed. I will implement this way and let you know if I have further questions.

@unikitty37 commented on May 19th 2021

As I mentioned in #17581, "When someone clicks on the X icon on the right then we don't show it for another 6 months." should be "never", not "6 months".

This Issue was closed on March 17th 2021
Powered by GitHub Issue Mirror