[Chartjs]-Ajax won't retrieve the data from my script

2👍

You are getting 1,2,3,4 because they are hardcoded. Try changing

var appelsnum =[1];
var mailsnum =[2];
var anomaliesnum =[3];
var decnum =[4];

to

var appelsnum =[data[0]];
var mailsnum =[data[1]];
var anomaliesnum =[data[2]];
var decnum =[data[3]];

Leave a comment