Skip to content
leonbarrett edited this page Nov 9, 2010 · 1 revision

Explanation

Allows you to pass in a number of data points, and then two labels for the X axis and two labels for the Y axis.

A formatted XML block will be returned.

API Call

$this->geckoboard_api->return_geckoboard_graph($data);

Usage

$data = array();
		
foreach($values as $value){
   $data[] = $value;
}
		
$min = min($data);
$max = max($data);
				
$data['axisx'][0] = AXIS_X_LABEL1;
$data['axisx'][1] = AXIS_X_LABEL2;
		
$data['axisy'][0] = $min;
$data['axisy'][1] = $max;
		
$data['colour'] = 'ff9900';
		
$response = $this->geckoboard_api->return_geckoboard_graph($data);
		       	
echo($response);

Clone this wiki locally