Piwik 0.6 Bug bei älteren php Versionen

Mai 6, 2010 – 7:56 pm

Habe heute das neue Piwik 0.6 installiert und eine meiner Lieblingsfehler bekommen:

Object of class Piwik_Date to string conversion

Das Problem bei älteren php Versionen ist, dass man die Daten vorher noch als String konvertieren muss, ansonsten gibts keine Statistiken.
Es sind nur 2 kleine Änderungen im Core notwendig:

#core/ViewDataTable/GenerateGraphData/ChartEvolution.php

157 157 'action' => 'index',
158 158 'idSite' => $idSite,
159 159 'period' => $period->getLabel(),
160 old 'date' => $dateInUrl,
160 new 'date' => $dateInUrl->toString(),
161 161 ));
162 162 $axisXOnClick[] = $link;
163 163 }

#
TabularUnified core/ArchiveProcessing.php

624 624 Piwik_Query($query,
625 625 array( $this->idArchive,
626 626 $this->idsite,
627 old $this->period->getDateStart(),
628 old $this->period->getDateEnd(),
627 new $this->period->getDateStart()->toString('Y-m-d'),
628 new $this->period->getDateEnd()->toString('Y-m-d'),
629 629 $this->periodId,
630 630 date("Y-m-d H:i:s"),
631 631 $record->name,

Nach den Änderungen gehen auch die Statistiken wieder :)

Share and Enjoy:
  • Digg
  • del.icio.us
  • Netvouz
  • MisterWong
  • Technorati
Tags: , ,

Kommentar schreiben

*
To prove you're a person (not a spam script), type the security word shown in the picture. Click on the picture to hear an audio file of the word.
Click to hear an audio file of the anti-spam word