I have read through the doc and did a search on the site. Read other forum post and am finding nothing. I am using the PHP Tracker API to import data from a past experience. All the actions were logged in another database and I am pulling it out and then inputting it into piwik with the API.
This is the general set up :
public function add_pageview_to_piwik($params){
$this->t->setUserAgent( "Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB) Firefox/3.6.6");
$this->t->setBrowserLanguage('en-us');
$this->t->setBrowserHasCookies(false);
$this->t->setResolution( 1024, 768 );
$this->t->setPlugins(false,true);
$this->t->setLocalTime( $params['localTime'] ); //'H:M:S"
$this->t->setTokenAuth( $this->piwik_token );
$this->t->setIp( $params['ip'] );
$this->t->setUrlReferrer( $params['urlReferrer'] );
$this->t->setForceVisitDateTime( $params['visitTime'] ); //'2011-04-05 23:55:02'
$this->t->setUrl( $params['url'] );
$this->t->setVisitorId( $params['visitorID'] );
$this->t->setCustomVariable( 1, 'stage', $params['stage'] );
$this->t->setCustomVariable( 2, 'weekday', $params['weekday'] );
if("Send" == $params['stage']){
$this->t->setCustomVariable( 3, 'allowLibrary', $params['allowLibrary'] );
if(!empty($params['videoImpressions'])){
$this->t->setCustomVariable( 4, 'videoImpressions', $params['videoImpressions'] );
}
if(!empty($params['videoViews'])){
$this->t->setCustomVariable( 5, 'videoViews', $params['videoViews'] );
}
}
$response = $this->t->doTrackPageView( $params['title'] );
fwrite($this->fp_response, $response);
}
on the last lines i am putting the response into a file to see what it is. This is what i am seeing repeated again and again in the file "
GIF89a^A^@^A^@<80>^@^@^@^@^@^@^@^@!ù^D^A^@^@^@^@,^@^@^@^@^A^@^A^@^@^B^BD^A^@;
"
This is basically all from a touch screen interface on an application. So i am setting the visitor id to a new id when i realize that a new person has started the process. it is just 1000000000000000 (16 char) which just gets incremented by 1 every time it is a new user.
I have the params values printed out everytime. one of which looks like this :
---------------------------------------------Array
(
[urlReferrer] => http://messagetogothamkiosks.com
[ip] => 75.204.74.22
[visitTime] => 2012-06-06 19:10:23
[localTime] => 19:10:23
[url] => http://messagetogothamkiosks.com/Catwoman
[stage] => Catwoman
[weekday] => Wednesday
[title] => Catwoman | Message to Gotham Kiosks
[visitorID] => 1000000000000002
)
or
---------------------------------------------Array
(
[allowLibrary] => 0
[videoImpressions] => 0
[videoViews] => 0
[urlReferrer] => http://messagetogothamkiosks.com/Batman/Info/Record/Share
[ip] => 75.204.74.22
[visitTime] => 2012-06-11 16:34:01
[localTime] => 16:34:01
[url] => http://messagetogothamkiosks.com/Batman/Info/Record/Share/Send
[stage] => Send
[weekday] => Monday
[title] => Send | Share | Record | Info | Batman | Message to Gotham Kiosks
[visitorID] => 1000000000000005
)
This function is hit 1000x in a batch. I have a usleep(200) at the end of each entry to slow it down a little bit. and it is also slowed down a little bit because it is pulling together other things (like other apis to make this entry.
there are the correct amount of entries in piwik_log_link_visit_action. But none of the reports have anything. i tried calling the archive.php manually with my token in the url string but it never says that there are files to process. I put in test user generated data from the core plugin and that works fine. Not sure if maybe because the visitor log in date, which i have set is so long ago (feb-apr) that piwik is not catching them and making reports from them.
i have executed this from the command line and the browser both without it timing out (because i am only doing 1000 at a time). i also have waited over night to see if the reports just needed time to get done.
There is also a small thing where it is possible to have like 100 different visitors from the same ip, one after another (because it is a standing kiosk in a public area) and i have that delineated by setting explicitly the visitor id but it doesn’t seem to be loyal to my input, as it has (in the visitor log) some visitors to have 300 actions etc. Because it is possible for there to be a 40 sec difference in times and have it be a different visitor (as I have set in the id).
I will most definitely provide any more information that might help. I have come at this from whatever angle I can think of.