I am creating a pie chart using chart.js; however, the value I want in the pie chart is a PHP variable. How do I add it to the pie chart? Currently I have this for the data for the pie chart:
var pieData = [
{
value: 40,
color:"green"
},
{
value : 40,
color : "red"
}
];
However, I need to replace the two 40s with PHP variables.