Hi,
I need some help with the data within a linked chart, I'm trying to use a while loop to populate the data within the linked chart, I thought I had it figured out but it doesn't seem to work, any help would be appreciated. Here's the code I have for the while loop.
array_push($arrData["linkeddata"], array(
"id" => "2016",
"linkedchart" => array(
"chart" => array(
"caption" => "Yearly spend",
"xAxisName" => "Year",
"yAxisName" => "Spend (In GBP)",
"formatNumber" => "1",
"yFormatNumber" => "1",
"formatNumberScale" => "0",
"decimalSeparator" => ".",
"thousandSeparator" => ",",
"numberPrefix" => "£",
"rotateValues" => "0",
"placeValuesInside" => "0",
"rotateValues" => "1",
"decimals" => "2",
"valueFont" => "Arial",
"valueFontColor" => "#000",
"valueFontSize" => "12",
"valueFontBold" => "0",
"valueFontItalic" => "0",
"theme" => "fint"),
"data" => array(
while ($Spend = $SpendData->fetch(PDO::FETCH_ASSOC)) {
array(
"label" => $Spend['Year'],
"value" => $Spend['SpendValue']
),
}
)
)
));