Hi, All

Programming Language PHP
Database: MySql
Level: beginner

I have two arrays

$n = array('Home', 'Office', 'Lib', 'Kaufland', 'Bib');
$v = array(100, 200, 300, 400, 500);

........
// Now I would like to display it in Pie Chart but i have error on line 32
:-(

29. <?php
30. $i = 0;
31. $piChart = new gPieChart();
32. for (i=0;i<n.length;i++){
33. $piChart->addDataSet(array(v[i]));
34. $piChart->setLegend(array(n[i]));
35. $piChart->setLabels(array(n[i]));
37. }
38. ?>

ERROR: *Parse error*: parse error, expecting `';'' in *
C:\wamp\www\.........\gChartExample.php* on line *32*
*
*
I know i am doing some stupid mistake but i already did this b4 with
googlevisualization api but i want to generate png instead of SVG so it can
be displayed on Android mobile devices.



-- 
Atif Musaddaq
Master in Media Informatics,
RWTH Aachen & University of Bonn,
Germany.
[email protected]

*”Design can be art. Design can be aesthetics. Design is so simple, that’s
why it is so complicated.” —Paul Rand*

-- 
You received this message because you are subscribed to the Google Groups 
"Google Chart API" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/google-chart-api?hl=en.

Reply via email to