Piwik app not injecting code


I installed the piwik app and it is not injecting the code. I followed the instructions but nothing, nada. Is anybody else having that problem?`

When I add the code manually to the site it is behaving oddly. It is only logging “some visits” for example, it logs visits from my cell phone but not from my desktop, even though the piwik code is present.

The webserver is behind cloudflare, the piwik server is not.

Does anybody have an idea? I thought having the piwik app inject the code might fix it, but like I mentioned, that does not work.