Class 'FrontController' not found error in Piwik 2.0

Hi all,

We’ve been running Piwik 1.x versions for a while with API PHP calls on our website with no issues. When trying out 2.0 in our DEV site and using the code suggested at http://piwik.org/docs/analytics-api/calling-techniques/#toc-call-the-piwik-api-using-the-rest-api-over-http , we seem to get an error such as the below:

2013/11/30 04:46:22 [error] 29258#0: *65 FastCGI sent in stderr: “PHP message: PHP Fatal error: Class ‘FrontController’ not found in /home/howsto/dev/wp-content/plugins/h2-piwikNEW/h2_piwik2_0.php on line 71” while reading response header from upstream, client: 60.240.246.182, server: dev.howsto.com, request: “GET / HTTP/1.1”, upstream: “fastcgi://127.0.0.1:9000”, host: “dev.howsto.com

Has anyone seen this issue before? We’re running Nginx 1.4.4 / PHP 5.4.22 (fpm-fcgi).

Thanks
Rob

Hmm, i get the error below when using the Call the Piwik API in PHP example.


Fatal error: Class 'Piwik\FrontController' not found in /home/*****/public_html/stats/apitest.php on line 19

I’m running Piwik 1.12 (currently latest stable)
PHP 5.3.22

Greetings,
Manuel

@symbiote the code on the doc site does not have “frontController” so maybe you copied wrong code?

@Manuel it’s normal it does not work in 1.12 we have already updated the documentation for 2.0

Hi there,

We are following guides such as here for implementing API calls via our PHP website:

http://piwik.org/docs/analytics-api/calling-techniques/#toc-call-the-piwik-api-in-php

Should we be referring to a different document? Which are you referring to?

Thanks!

The docs work for the latest 2.0 beta see: 301 Moved Permanently