Function __global->stats_generate_graph_form

Definitions

sources/stats.php

  • Generate a stats graph filter form.
  • Visibility: public
  • Is abstract?: No
  • Is static?: No
  • Is final?: No
  • Returns: object

Parameters

Name Type Passed by reference? Variadic? Default Set Range Description
$graph_name string No No required parameter N/A N/A Graph name
&$hook_ob ?object Yes No Null N/A N/A Hook object (null: look it up using $graph_name)
&$graph_details ?array Yes No Null N/A N/A Graph details (null: look it up using $graph_name)
$filters array No No [] N/A N/A Filter settings to take precedence
$pivot ?mixed No No Null N/A N/A Pivot value to take precedence (null: none)
$for_kpi boolean No No False N/A N/A Whether this is for setting up a KPI

Returns

  • Graph filter form
  • Type: Tempcode
  • Set: N/A
  • Range: N/A

Preview

Code (PHP)

/**
 * Generate a stats graph filter form.
 *
 * @param  string $graph_name Graph name
 * @param  ?object $hook_ob Hook object (null: look it up using $graph_name)
 * @param  ?array $graph_details Graph details (null: look it up using $graph_name)
 * @param  array $filters Filter settings to take precedence
 * @param  ?mixed $pivot Pivot value to take precedence (null: none)
 * @param  boolean $for_kpi Whether this is for setting up a KPI
 * @return Tempcode Graph filter form
 */

function stats_generate_graph_form(string $graph_name, ?object &$hook_ob = null, ?array &$graph_details = null, array $filters = [], $pivot = null, bool $for_kpi = false) : object