Hi,
I have the following code so far :
[code]<?
$myarray = array( 0 => array( ‘year’ => 2009, ‘month’ => “November”, ‘month_sales’ => 524, ‘year_totalsales’ => 3610 ),
1 => array ( ‘year’ => 2009, ‘month’ => ‘December’, ‘month_sales’ => 521, ‘year_totalsales’ => 3610 ),
2 => array ( ‘year’ => 2010, ‘month’ => “January”, ‘month_sales’ => 609, ‘year_totalsales’ => 3610 ));
$lastyear = “”;
echo “
Month | Sales |
---|---|
”, $row[‘year’], “ | |
”, $row[‘month’], “ | ”, $row[‘month_sales’], “ |
?>
[/code]
BUt this code gives me this:
[code]
Month | Sales |
---|---|
2009 | |
November | 524 |
December | 521 |
2010 | |
January | 609 |
Instead of this:
[CODE]
Month | Sales |
---|---|
2009 | |
November | 524 |
December | 521 |
Month | Sales |
---|---|
2010 | |
January | 609 |
ANy help appreciated thx