Thomas
Forum Replies Created
-
Hi @codeispoetry
thanks for creating the issue. I have installed the same plugin and been looking through the code as well as been trying to find the issue for quite a while on the link you mentioned (you probably notice my visit in the visits log 🙂 ).It looks like this is due to https://github.com/matomo-org/matomo/issues/15780
Basically, Matomo is working as expecting and adding the click listener to all links on the page including the PDF links etc. However, there seems to be something dynamic like you say and Zotpress seems to replace the link elements or so and as such Matomo is not tracking these links.
If I call
_paq.push(['enableLinkTracking'])after the page loaded again, the links are tracked. I couldn’t quite figure out how/where Zotpress is replacing these link elements and why they would do it. However, maybe a few things could help improve the situation until we have fixed above referenced issue.* I reckon you can disable content impressions (unless you actually changed your theme to support it)
* You can likely remove all the addDownloadExtensions, setDownloadExtensions, setLinkClasses . They shouldn’t be needed and I assume you did it for debugging purposes and trying to make it work.Now you have two options:
1. If you have a custom theme and you are a developer, then you could add something like this to your theme
setTimeout(function () { window._paq = window._paq || [];window._paq.push(['enableLinkTracking']) }, 4000)2. Assuming you likely don’t have a custom theme and maybe aren’t a developer, you could:
* Change the tracking mode in Matomo tracking settings from “Default tracking” to “Enter manually”.
* Then copy above code with the set timeout and paste it add the end of the “tracking code” field.
* Then save the changes.It might not work in all cases, but it should improve the situation. It will basically 4 seconds after it executes that code search for links to track. The zotpress link elements might be replaced by then, or not depending on how fast the page loads so it wouldn’t always work.
I hope this doesn’t sound all too confusing and feel free to otherwise create a user with the Matomo Super User role for us (email: wordpress at matomo.org) and we help you getting it to work. Sorry about all the trouble! I will see if we can also solve this in the next release already partially.
Blown away by this plugin. Very well-executed and amazing that it basically all works out of the box!
That’s great to hear! Feel free to leave a review, it would really help us 🙂
Let me know any questions and again sorry if it got a bit technical.
@samuelzee BTW do you mind checking in your
wp-config.phpwhat your DB_CHARSET variable is set to in case you know how to look this up?Thanks @starmansk
Very much appreciated. This was a big help. We have prepared a fix for this here: https://github.com/matomo-org/wp-matomo/pull/265/files and this fix will be included in the next update.
The reporting and admin works now. However, some links in the Matomo reporting top menu and dashboard are looking “unstyled” now. I have debugged this for quite a while and it seems that plugin is using an older version of a library called “Twig” causing these issues likely. I will try to inform these developers so maybe they can have a look.
Thanks for your help again.
Thanks @starmansk
Any chance you could send us the system report (see https://matomo.org/faq/wordpress/how-do-i-find-and-copy-the-system-report-in-matomo-for-wordpress/ on how to get it) as a comment here (it should be anonymised) or by sending it to wordpress@matomo.org ?
In case you are familiar with editing files on your server, do you mind editing the file
wp-content/plugins/matomo/plugins/WordPress/WordPress.phpand basically for a short test add the two characters//to this line 293 as shown here: https://github.com/matomo-org/wp-matomo/compare/master…wpsuptest?quick_pull=1#diff-9cd2edfc2a1dd8cea8c7c7f553b1c6aaR293 ? If you add these two characters temporarily, does it work then?Thanks @starmansk I can now view the image. Does this image happen only in the admin of Matomo? Only when you perform a certain action maybe?
Hi @starmansk a few hours ago I requested access to this screenshot. Be great to give me access otherwise I won’t be able to look into it. Cheers
Of course @thegulshankumar take as much time as you want. Feel free to comment any time here and we’ll get back into it.
@arfufu marking this issue as resolved for now. Feel free to comment again should the issue come up again.
@badr2020 We have added a new setting in “Matomo -> Settings -> Advanced”
If it was detecting the wrong location because it was using the server IP, you can now select a different proxy IP header. The UI will explain it.
Besides this we have also added some additional checks for location in the system report that indicate whether things work as expected.
@samuelzee have you maybe had a chance to look at my last comment?
@doyenwilliams as mentioned this is a PHP configuration issue. We can’t solve this in the plugin unfortunately. I recommend you check with your hoster or sysadmin to get the configuration sorted. The PHP extension “imagick” is basically configured twice.
@thegulshankumar I suppose the issue is resolved as I haven’t heard from you in a while or maybe you’re not using the plugin anymore. Feel free to ping me here any time should you find it slow again.
I see. It’s unfortunately not possible. That’s basically where you would need to use Matomo On-Premise unfortunately. Sorry I don’t have better news in regards to this.
Glad it seems to be ok now.
You can definitely ignore the warning around 32MB/64MB.
Not quite sure what you mean with another database? We only support MySQL. However, you can install Matomo On-Premise in another database see https://matomo.org/docs/installation/ It is then completely separated from WordPress and tracking and reporting UI should be faster as the WordPress part is gone.
> I also added the 3 new lines in SystemReport.php and we will if the error comes back 🙂
Awesome, thanks for that!
Seems a bit of a mystery. If the “puc_cron_check_updates” and “wp_version_check” fails it seems maybe your server is trying to connect to some external server but it is failing.
The updated system report looks pretty much good. It be great to have an eye on it to see if it happens again. I see you have enabled “InvalidateReports” plugin as well. Did this maybe start happening after invalidating some reports by any chance?