viernes, 27 de julio de 2012

 librería JpGraph,  PHP, mysql.

img->SetAntiAliasing(); 
$graph->SetMarginColor('gray'); 
//$graph->SetShadow(); 

// Setup margin and titles 
$graph->title->Set("Productos Mas Comprados"); 

$p1 = new PiePlot3D($array); 
$p1->SetSize(0.35); 
$p1->SetCenter(0.5); 

// Setup slice labels and move them into the plot 
$p1->value->SetFont(FF_FONT1,FS_BOLD); 
$p1->value->SetColor("black"); 
$p1->SetLabelPos(0.2); 

//$nombres=array("pepe","luis","miguel","alberto"); 
$p1->SetLegends($nombres); 

// Explode all slices 
$p1->ExplodeAll(); 

$graph->Add($p1); 
$graph->Stroke(); 
?>

1 comentario:

  1. 1. descargar la librería de http://jpgraph.net/download/
    2. la carpeta src la renombre a jpgraph de alli requiero:
    include ("jpgraph/jpgraph.php")
    include ("jpgraph/jpgraph_pie.php")
    include ("jpgraph/jpgraph_pie3d.php")
    3. de la carpeta examples escojo uno y modifico, me ayude de
    http://www.desarrolloweb.com/articulos/1987.php.
    PD:FALTA INVESTIGAR MAS SOBRE EL TEMA MEJORAS SERIA CHVR ...

    Gracias Dios por darme la luz. (:

    ResponderEliminar