Location: PHPKode > projects > WEB-PA > spider/include/crea_grafico_generico.php
<?php
/*
Questa pagina crea un grafico a partire dalla valutazione e il parametro di ricerca
*/
define('paos_INCLUDE_PATH','./');
require(paos_INCLUDE_PATH.'config.inc.php');

require(paos_INCLUDE_PATH.'funzioni_report.php');

include (paos_INCLUDE_PATH."/jpgraph/src/jpgraph.php");    
include (paos_INCLUDE_PATH."/jpgraph/src/jpgraph_bar.php"); 


$etichette = array_keys($_GET);
$valori = array_values($_GET);


$graph = new Graph(450,250,"auto"); 
$graph->SetScale("textint"); 
$graph->img->SetMargin(50,10,50,100); 
$graph->SetShadow(); 

$graph->xaxis->SetTickLabels($etichette); 
$graph->xaxis->SetFont(FF_ARIAL,FS_BOLD); 
$graph->xaxis->SetLabelAngle(-70);

$bplot = new BarPlot($valori); 
//$bplot->SetFillColor("lightgreen"); // Fill color 
$bplot->SetFillGradient("blue","yellow",GRAD_MIDVER); 
$bplot->value->Show(); //Per fare vedere il valore sopra la colonna
$bplot->value->SetFont(FF_ARIAL,FS_BOLD); 
$bplot->value->SetAngle(45); 
$bplot->value->SetColor("black","navy"); 

$graph->Add($bplot); 
$graph->Stroke(); 



?>
Return current item: WEB-PA