Hello,
I’m building a plug-in for Piwik and I have some problem with the hooks.
I have the code below:
final function getListHooksRegistered() {
return array(
'Tracker.knownVisitorInformation' => 'logKnownAction' ,
'Tracker.Action.record' => 'logAction',
'Tracker.newVisitorInformation' => 'logNewVisit',
);
}
I swap the hooks in the array and it seems that only the first hook is called.
For example, when I begin a new visit and click on a page, only the hook knownVisitorInformation is triggered and not the Action.Record.
Am I doing something wrong ?
Another question, the “KnownVisitorInformation” event is occurring only once in a visit, am I right ?
Thanks you
Edit: I tried with the both hooks:
'Tracker.Action.record' => 'logAction',
'Tracker.saveVisitorInformation.end' => 'logVisit',
And it’s working well simultaneously, so I used them
Tia