Support » Plugin: WP-Piwik » Piwik proxy script doesn`t work

Viewing 13 replies - 1 through 13 (of 13 total)
  • Plugin Author braekling


    Actually the proxy mode works fine, so I need some more information about your configuration and what “does not work” means in fact to get behind your issue.

    Is the tracking code not shown? Is the proxy script not accessible? Is the script added as expected, but Piwik does not count? …

    Oh, sorry. Code is added on auto. I see it in source, but it doesn`t send any stats to piwik.

    Plugin Author braekling


    And the code is added as expected?

    Does YOUR_DOMAIN/wp-content/plugins/wp-piwik/piwik.php show the tracking client code?

    Do the other tracking modes work?


    <!-- Piwik -->
    <script type="text/javascript">
      var _paq = _paq || [];
      (function() {
        var u=(("https:" == document.location.protocol) ? "https" : "http") + "://MYDOMAIN.COM/wp-content/plugins/wp-piwik/";
        _paq.push(['setTrackerUrl', u+'piwik.php']);
        _paq.push(['setSiteId', 2]);
        var d=document, g=d.createElement('script'), s=d.getElementsByTagName('script')[0]; g.type='text/javascript';
        g.defer=true; g.async=true; g.src=u+'piwik.php'; s.parentNode.insertBefore(g,s);
    <!-- End Piwik Code -->

    When I navigate to wp-content/plugins/wp-piwik/piwik.php, I see GIF Image 1×1 in center.

    I tried Default tracking, but seems, that it doesn`t send data to main PIWIK, I can see that data in WP-PIWIK only.

    Plugin Author braekling


    WP-Piwik just gets the tracking code using Piwik API, does some changes (if necessary) and adds it to your blog. Furthermore, WP-Piwik gets analytics data from Piwik and shows it inside the WordPress dashboard.

    WP-Piwik neither tracks by itself nor stores tracking data… if values are shown in WP-Piwik, they have to be available in Piwik, too. Maybe you should check your date settings in Piwik? By default it does not show today’s data.

    If you open the proxy PHP script, you should get a JavaScript code, e.g., see

    Ok, I see. I have set Piwik to show today by default.

    First tracking option works fine, without any problems, but I need to use piwik.php proxy.

    Here is what I see in my browser Tab, when I try to load piwik.php (wp-content/plugins/wp-piwik/piwik.php):

    I tried another thing to check, if this problem is not caused by server:
    I uplodaded piwik.php script from developers to root domain, configured it. Then I added javascript code to my page footer with main piwik details and it worked, Piwik shows stats.

    I am trying to figure out, what`s blocking that connection between your plugin proxy and piwik analytic. All I done, is ticked box to Use proxy script and add javascript to footer. And why when I navigate to piwik.php I see gif… Mystic for me. Maybe I need to edit some permissions through ftp? Any Ideas?

    Plugin Author braekling


    Hm, can you check your .htaccess files in your WordPress folder, your wp-content folder and your wp-content/plugins folder?

    Meanwhile, I will check if the piwik.php script may cause this issue on his own (e.g., by delivering a gif header or something similar…).

    WordPress htaccess
    # BEGIN WordPress
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteRule ^index\.php$ – [L]
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]

    # END WordPress

    There is none htaccess in plugin folder and wp-content.

    Here are the permissions: 0755 for wp-content and plugins. For piwik.php located in wp-piwik folder is 0644.

    Plugin Author braekling


    Can you give me the response header of piwik.php?

    If you don’t know how to get it using your browser, try a tool like – just enter the full URL of piwik.php, click “Check Headers” and copy the result.

    Ok, here is the result:

        Sun, 22 Jun 2014 15:51:49 GMT
        timeout=5, max=100
        popover_view_4721c91e4074095d276cfbb7ed556ae5=1; expires=Thu, 04-Jun-2015 21:11:49 GMT; path=/
        public, max-age=604800
        Sun, 29 Jun 2014 15:51:49 GMT

    Plugin Author braekling


    Ok, thank you. Two more questions: Are you using WP-Piwik in network mode? And are you using the REST or the PHP API?

    I am using REST MODE. Could you please explain more about ” Are you using WP-Piwik in network mode? “? Didn`t understand.

    Plugin Author braekling


    Are you using WordPress in network mode (one WordPress setup for many blogs, ) or are you using just a simple WordPress?

Viewing 13 replies - 1 through 13 (of 13 total)
  • The topic ‘Piwik proxy script doesn`t work’ is closed to new replies.