Opened 3 years ago

Closed 3 years ago

#2417 closed Bug (fixed)

Fatal error: Call to undefined method Piwik_DataTable_Array::getRows() in /var/www/piwik/core/DataTable/Renderer/Html.php on line 83

Reported by: glens Owned by:
Priority: major Milestone: 1.5 - Piwik 1.5
Component: Core Keywords: api
Cc: Sensitive: no

Description

When using the API with the Html output and the 'lastX' date value, I get the error above.

index.php?module=API&method=Referers.getSearchEngines&idSite=all&period=day&date=last2&format=Html&token_auth=

example URL. Apparently, getRows() is not a method. This bug is compounded by the fact that later, there is no getColumns() method in Piwik_DataTable, so the majority of this does not work.

Change History (5)

comment:1 Changed 3 years ago by glens

Please note, that this is only the combination of multiple idSite values (or all), the Html renderer, and a lastX date value. No other combination of these values seems to trigger this problem.

Also, I'm using version 1.3 currently.

comment:2 Changed 3 years ago by ziegenberg

Applies to Version 1.4 as well.

comment:3 Changed 3 years ago by matt (mattab)

  • Milestone set to 1.5 - Piwik 1.5

comment:4 Changed 3 years ago by SteveG (sgiehl)

HTML DataTable Renderer can't handle that case at the moment. If more that one siteId is given there will be DataTableArrays within a DataTableArray. The HTML-Renderer only handles one dimension of DataTableArrays.

comment:5 Changed 3 years ago by matt (mattab)

  • Resolution set to fixed
  • Status changed from new to closed

(In [4829]) Error message when unsupported combination of parameters (please use json or XML or csv which work, HTML is designed only as a debug/test output) fixes #2417

Note: See TracTickets for help on using tickets.