You are here

function _statspro_path_aggregated_get_table_data in Statistics Pro 6.2

Returns the provided path aggregated data in the default table format.

Parameters

<array> $path_aggregated_data:

Return value

<array>

1 call to _statspro_path_aggregated_get_table_data()
statspro_path_aggregated_get_data_for_configurable_period_report in ./statspro_path_aggregated.inc

File

./statspro_path_aggregated.inc, line 579

Code

function _statspro_path_aggregated_get_table_data($path_aggregated_data) {
  $table = array();
  $table['headers'] = array(
    t('Path aggregator'),
    t('Access counter'),
    t('Session'),
    t('Machine'),
  );
  $rows = array();
  foreach ($path_aggregated_data as $path_aggregator) {
    $row = array(
      $path_aggregator['name'],
      (int) $path_aggregator['access_counter'],
      count($path_aggregator['sessions']),
      count($path_aggregator['hosts']),
    );
    $rows[] = $row;
  }
  $table['rows'] = $rows;
  return $table;
}