Quantcast
Channel: Piwik Forums - Support & Bugs
Viewing all 13117 articles
Browse latest View live

Re: Piwik multiple domains - tracking on one but not another

$
0
0
The problem still persists. The code seems to be ok. I can see it in the source of the page on the domain that is not tracked. So the problem must be with Piwik.

Anyone had same problems and solved it?

Track same user by JS and PHP

$
0
0
I'm trying to track the same user with JS and PHP. AFAIK I must set the piwik visitor id on the php side, so piwik knows it is the same user. I am trying to do it with this:

$_p = new PiwikTracker( $id, $piwik_url );
$_p->setTokenAuth( $piwik_token );
$_p->setIp( $_SERVER['REMOTE_ADDR'] );
$_p->setVisitorId( $visitor_id );

The only problem is to set the right $visitor_id. First, I thought I can get it by JS like this:

var visitor_id;
_paq.push(function() { visitor_id = this.getVisitorId(); });

And then send the visitor_id to the server. But the visitor_id I get by this is always a different one from the one getting logged in the sql table log_visits in column idvisitor and therefore in the visitor log I get two different users.

I looked at the cookies that are sent to the piwik instance and my php site, too. There is always a cookie like the following:

_pk_id.<SITE_NUMBER>.4014=<VISITOR_ID>.1367416459.1.1367417149.1367416459.;

the <VISITOR_ID> is the same one I get by this.getVisitorId() in javascript. So this again is not the one I need.

How can I track the same user by JS and PHP? Is this possible? Can I get the visitor_id used by piwik in some way or is there another solution?

Working on Apache Logs

$
0
0
Hey folks!

Yes, I did read the FAQ, Manual and spent about an hour of google'ing around. So far I came across outdated versions or no longer valid informations.
Summary: I do have piwik up and running, even with GeoIP stuff, so far it works great. Now, I can't modify the websites of the pages, so I have to rely on the apache logs, which I already modified to include the requested (sub)domain. Logs are in /var/log/http/$domain/$fqdn-access.log, ie, /var/log/http/tree.com/stump.tree.com-access.log. There are always new hosts / domains coming and going, so there is an unknown number of subdomains to be handled.

I built my log-import script like this:
#! /usr/local/bin/bash

# Configuration
BIN="/usr/local/www/piwik/misc/log-analytics/import_logs.py"
URL="http://server/piwik/"
SMP="4"
EXTRA="--enable-http-errors --enable-http-redirects --enable-static --enable-http-redirects --enable-reverse-dns --enable-bots --add-sites-new-hosts"

find /var/log/httpd/ -type f -iname "*access*" | xargs $BIN --url=$URL --recorders=$SMP $EXTRA

This actually adds new sites for... new sites (duh), as required. All nice and easy - yay!

Now the tricky part, also known as Problem (dun-dun-dun)...
The logfiles are deleted each month (actually backed-up, then deleted). This also means that until then, the logs are not rotated. The beforementioned script does run every 3 hours, yielding in what I can see in pretty much duplictated entries. Hence the problem. (Is this a bug or a missing feature?)

I also noticed there is an archive.php script, which use is currently a mistery to me. Does this delete the duplicated entries? After a run of archive.php a site that had 4 visits (really 2 visits, but with one duplictate log entry 4) still remains 4. It does drop if I delete all the piwik_archive_* tables, but uh... This would mean I'd have to:

- run the update script,
- run the archive script,
- drop all archive dbs.

every 3 hours!

I know I am missing something blatantly obvious here. The question is: How do I really go for updating Piwik with apache logs (which can't be rotated)?

Thank you very much in advance,
great work with piwik,
-Christian.

POSTing to piwik.php just hangs

$
0
0
Hello all,

I'm trying to post data to the /piwik.php page and I'm getting nothing but a hanging script. I can visit the page, I can send a query string over GET, but every time I try to post I get nothing. I've turned on debugging and still, nothing.

To test, I've set up a small page on the same server that just posts the data over an ajax post request and spits back whatever piwik answered with. It's just spinning without ever ending.

I can run the bulk import tool from the command line on the server and there is no problem.

I've also updated to the latest beta, but it wasn't working before the upgrade either.

For refrence, I'm sending the data from the piwik documentation (firebug output):
{"requests": ["?idsite=1&url=http://example.org&action_name=Test bulk log Pageview&rec=1","?idsite=1&url=http://example.net/test.htm&action_name=Another bul k page view&rec=1"], "token_auth": "mytokenishere"}

Any help would be much appreciated.

John

Re: POSTing to piwik.php just hangs

$
0
0
Ok, I think I see why it wasn't working from my webpage... same origin policy. But I am also trying to post from a script which is not using javascript/ajax requests, and I'm still getting the same issue.

Can we use Piwik framework for custom analytics?

$
0
0
Hi Team,

I am very much impressive with this MVC framework and everything dynamic (using smarty template engine). so can we use this framework for other than web analytics?

Thanks,
Vijay

Re: Website Privilige Exception after Update to 1.10.1

$
0
0
Hi,

I had the same issue, only for one username, no changes were made, but for some reason it did now point to ID 1 instead of 4. The user reported he can not login after being able to login for several months prior. Is this a bug or something that should be checked? It took me almost an hour to figure this out. Thanks for the fix here but just strange that this happened.

I use Piwik 1.11.1

Best wishes,
Thom

Re: Archiving not working - empty API respopnse

$
0
0
Hi Matt,

Below is a copy of the server logs:

[Tue Apr 30 00:00:48 2013] [error] [client 178.63.49.169] #2 TCPDF-&gt;getRandomSeed(...) called at [/home/greenerl/public_html/libs/tcpdf/tcpdf.php:1912]<br />
[Tue Apr 30 00:00:48 2013] [error] [client 178.63.49.169] #3 TCPDF-&gt;__construct(...) called at [/home/greenerl/public_html/core/ReportRenderer/Pdf.php:78]<br />
[Tue Apr 30 00:00:48 2013] [error] [client 178.63.49.169] #4 Piwik_ReportRenderer_Pdf-&gt;__construct(...) called at [/home/greenerl/public_html/core/ReportRenderer.php:51]<br />
[Tue Apr 30 00:00:48 2013] [error] [client 178.63.49.169] #5 Piwik_ReportRenderer::factory(...) called at [/home/greenerl/public_html/plugins/PDFReports/PDFReports.php:298]<br />
[Tue Apr 30 00:00:48 2013] [error] [client 178.63.49.169] #7 call_user_func_array(...) called at [/home/greenerl/public_html/libs/Event/Dispatcher.php:284]<br />
[Tue Apr 30 00:00:48 2013] [error] [client 178.63.49.169] #8 Event_Dispatcher-&gt;postNotification(...) called at [/home/greenerl/public_html/core/PluginsManager.php:722]<br />
[Tue Apr 30 00:00:48 2013] [error] [client 178.63.49.169] #9 Piwik_PostEvent(...) called at [/home/greenerl/public_html/plugins/PDFReports/API.php:423]<br />
[Tue Apr 30 00:00:48 2013] [error] [client 178.63.49.169] #10 Piwik_PDFReports_API-&gt;generateReport(...) called at [/home/greenerl/public_html/plugins/PDFReports/API.php:522]<br />
[Tue Apr 30 00:00:48 2013] [error] [client 178.63.49.169] #12 call_user_func(...) called at [/home/greenerl/public_html/core/TaskScheduler.php:164]<br />
[Tue Apr 30 00:00:48 2013] [error] [client 178.63.49.169] #13 Piwik_TaskScheduler::executeTask(...) called at [/home/greenerl/public_html/core/TaskScheduler.php:79]<br />
[Tue Apr 30 00:00:48 2013] [error] [client 178.63.49.169] #14 Piwik_TaskScheduler::runTasks(...) called at [/home/greenerl/public_html/plugins/CoreAdminHome/API.php:38]<br />
[Tue Apr 30 00:00:48 2013] [error] [client 178.63.49.169] #16 call_user_func_array(...) called at [/home/greenerl/public_html/core/API/Proxy.php:189]<br />
[Tue Apr 30 00:00:48 2013] [error] [client 178.63.49.169] #17 Piwik_API_Proxy-&gt;call(...) called at [/home/greenerl/public_html/core/API/Request.php:127]<br />
[Tue Apr 30 00:00:48 2013] [error] [client 178.63.49.169] #18 Piwik_API_Request-&gt;process(...) called at [/home/greenerl/public_html/plugins/API/Controller.php:26]<br />
[Tue Apr 30 00:00:48 2013] [error] [client 178.63.49.169] #20 call_user_func_array(...) called at [/home/greenerl/public_html/core/FrontController.php:136]<br />
[Tue Apr 30 00:00:48 2013] [error] [client 178.63.49.169] #21 Piwik_FrontController-&gt;dispatch(...) called at [/home/greenerl/public_html/index.php:52]</div><br />

The problem occurred when I tried to seyup the Signup extension/plugin to allow multiple user signups. Even after removing it though, the system is simply not tracking any new traffic.

You assistance is greatly appreciated.

Unknow location with geoip

$
0
0
Hello,

I have a problem with geoip.

It shows location:unknown in the admin interface but I have the databases for countries and cities installed and known by Piwik (it tells me they are accessible).

Any help ?

Thanks.

Re: Can we use Piwik framework for custom analytics?

$
0
0
It's only the terminology that is bound to website/visits/actions really. You could just create a dummy "website" for the thing you want to track and map visits and actions to something else using the API.

Visitor Log

$
0
0
Hi,

I am quite new to the whole area of analytics so please bear with me.
I am having a bit of trouble understanding why the visitor log page on our evaluation server shows one row for each page I hit. It is only me browsing our web application. I have put the standard piece of async tracker script in the jsp header that is included on every page. When I browse around the application hitting different urls (within seconds of each other) I had expected this to be treated as one visit containing many actions but it looks to have been interpreted as many visits containing one action (the action shows different urls for each "visit").
Where have I gone wrong or misunderstood ?

Thanks for any thoughts.

Re: POSTing to piwik.php just hangs

$
0
0
Made a little more progress this morning with Fiddler 2. I was able to send a post request to piwik.php and get a response:

{"requests": ["?idsite=1&url=http://example.org&action_name=Test bulk log Pageview&rec=1","?idsite=1&url=http://example.net/test.htm&action_name=Another bul k page view&rec=1"], "token_auth": "mytokenhere"}


unfortunately, the response I get is

Debug enabled - Input parameters: <br/>array ( )
token_auth is authenticated!
Loading plugins: { Provider,Goals,UserCountry }
Current datetime: 2013-05-02 14:41:41
The request is invalid: empty request, or maybe tracking is disabled in the config.ini.php via record_statistics=0
token_auth is authenticated!
Loading plugins: { Provider,Goals,UserCountry }
Current datetime: 2013-05-02 14:41:41
The request is invalid: empty request, or maybe tracking is disabled in the config.ini.php via record_statistics=0
-> Scheduled tasks not triggered.
Next run will be from: 2013-05-02 15:25:24 UTC
Nothing to notice => default behaviour
End of the page.

I double checked and even put into my config.inc.php that record_statistics = 1, so I'm not sure what I'm doing wrong with this post request, as it's taken straight from the documentation and validates as json off of jsonlint.

Problems after upgrade to PHP 5.4

$
0
0
Hello,

after upgrading to PHP 5.4, I get

Quote

SQLSTATE[HY000] [2000] mysqlnd cannot connect to MySQL 4.1+ using the old insecure authentication. Please use an administration tool to reset your password with the command SET PASSWORD = PASSWORD('your_existing_password'). This will store a new, and more secure, hash value in mysql.user. If this user is used in other scripts executed by PHP 5.2 or earlier you might need to remove the old-passwords flag from your my.cnf file

I tried resetting the password, but it didn't help. How to fix this?

Re: Problems after upgrade to PHP 5.4

$
0
0
Check out this thread on Stack Overflow and see if it helps with your issue:
http://stackoverflow.com/questions/8831183/mysqlnd-cannot-connect-to-mysql-4-1-using-the-old-insecure-authentication

Re: Problems after upgrade to PHP 5.4

$
0
0
What do I do, if the DB is at a web hoster? What can I do in this case?

Re: Problems after upgrade to PHP 5.4

$
0
0
Do you have access to a control panel or other set up for your database? If not, I would contact their support and let them know about needed to update your password to the more secure one and maybe hint to them that it's time to upgrade their MySQL installation (latest version is 5.6, I'm using 5.5.29 on my install) as the newer password setup has been around for a number of years now.

An error occured while sending "HTML Email Report"

$
0
0
Hello everyone,

I been using piwik to monitor my site, where i made an report that every 1st day of the month an report would be sent to my mail box. Everything was working nicely, however this month instead of the usual e-mail with the statistics i got an e-mail with an error:

An error occured while sending 'HTML Email Report - 1.2013-04-25,2013-05-01.2.en.html' to someaddress@domain.com. Error was 'Permission denied'

i tried to send an e-mail from the box where the site is hosted (using bash/sendmail) and i got this mail test so im assuming nothing is wrong with the server configurations, also i checked the plugin and piwik configuration and nothing seens "bad". Anyone could give me a tip?

Using Piwik 1.11.1, php 5.3.3 on a CentOS 6.4. Thanks in advance

Edit: forgot to mentioned last month i upgraded to 1.11.1 and before that i been recieving the reports with no problem (doesnt mean this is the one at fault ofc ...)

ignore parameters -> cleanup

$
0
0
Hi!

Today I found out how to have Piwik ignore special parameters :)

Is there a way to clean up the information in my database? I mean, piwik will start ignoring that parameter from today on, but I would also like to have it ignored backwards to the whole timerange

Thx in advance :)

strange: piwik sometimes track, sometimes tracks not goals(td)

$
0
0
i have an stupid problem in virtuemart 2 (joomla online-shop component) - my goals are not tracked reliable. ~40 percent orders are definitely not tracked as goals .
In my old piwik-version (must have been next to last) I tried JS tracking by page-title and part of uri on confirmation page. this page refers to paypal after 2 seconds. So i thought: "ok, perhaps this is the problem: 2 seconds is not enough to track reliable. I simply track goals one page before, onSubmit.
Today in the morning i updated piwik to Piwik 1.11.1 and put following code in the page:

jQuery(document).ready(function($) {
$('span#buyButton a').attr('href', '#');
$('span#buyButton a').click(function(event) {
event.preventDefault();
logGoal(8.7);
$('#checkoutForm').submit();
});

...and before </body>:
<script type="text/javascript">
      var _paq = _paq || [];
      _paq.push(["setDocumentTitle", document.domain + "/" + document.title]);
      _paq.push(["setCookieDomain", "*.myurl.de"]);
      _paq.push(["trackPageView"]);
      _paq.push(["enableLinkTracking"]);

      (function() {
        var u=(("https:" == document.location.protocol) ? "https" : "http") + "://www.myurl.de/piwik/";
        _paq.push(["setTrackerUrl", u+"piwik.php"]);
        _paq.push(["setSiteId", "1"]);
        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.js"; s.parentNode.insertBefore(g,s);
      })();
    </script>
<script type="text/javascript">
        function logGoal(revenue){
            try {
                _paq.push(['trackGoal', 1, revenue]);
            }
            catch( err ) {}
        }
    </script>
<noscript>&lt;p&gt;&lt;img src="https://www.myurl.de/piwik/piwik.php?idsite=1" style="border:0" alt="" /&gt;&lt;/p&gt;</noscript>
I changed the goal to manual triggering an then quick-tested: my visit and the goal was tracked correctly.
But now in the evening i looked again: for the one order today there was no goal tracked! I really ask myself why, the button has to be klicked for everey order. nothing special in the order: the whole visit was tracked correctly.
I hope s.o. has a tip what i could test next.

Bye, Mojo

Database queries for site search usage

$
0
0
I am running Piwik 1.11 for a fairly large site, and we recently added site search to our site, and are tracking it in Piwik. The site search report is showing up in Piwik as one would have expected, so all is working well.

However, in using Piwik, I have become quite proficient in running SQL queries directly against the Piwik database to get answers to questions not readily available within the Piwik web interface (e.g. what proportion of users visiting page A subsequently visited page B, etc). I would like to do the same for search, but I cannot figure out how search information is captured in the database.

Could someone help me along? I am assuming that this must be done using the piwik_log_action and piwik_log_link_visit_action tables somehow, but I cannot figure out how it is working or where the data is stored. Given that the reports are showing up in the web interface, I know the data is stored somewhere, I just cannot find where. I have searched all documentation, tried to find the information in the Piwik code, searched the forums, but I am stumped.

Very grateful for clues.
Staffan
Viewing all 13117 articles
Browse latest View live