$cpt=0; $rownu =1;
while($row = mysql_fetch_row($result))
{
$data[$cpt][0] = $rownu;
$data[$cpt][1] = $row[0];
$data[$cpt][2] = $row[1];
$data[$cpt][3] = $row[2];
$rownu++;
$cpt++;
This worked perfectly
Fredrik..
thank you
jrt
"Fredrik De Vibe" <[EMA
[EMAIL PROTECTED] (John Thorne) writes:
[ snip ]
> $data[$cpt]=
> $rownu.","."\"".$row[0]."\"".",\"".$row[1]."\","."\"".$row[2]."\"";
This is a string, not an array.
> Could you go a step farther in the $foo[$i][$j] please
$data[$cpt][0] = $rownu;
$data[$cpt][1] = $row[0];
$data[$cpt][2] = $
Thanks for the reply
I do not under stand how to apply your example
$foo[$i][$j] = "bar";
Graph example array trying to create thru sql:
$data = array(
array(0,"Concept","2002-9-1","2002-9-15",blue),
array(1,"Creative","2002-9-15","2002-9-30",red),
array(2,"Produce","2002-9-31","2002-10-10",green
[EMAIL PROTECTED] (John Thorne) writes:
> $data[$cpt]= $row[0].",".$row[1].",".$row[2].",".$row[3].",".$row[4];
What you need is a two dimensional array. The code above concatenates
the $row elements into a string and puts this string into a one
dimensional array.
the 2D array $foo[3][5] can be s