I am filling up an object array, first I read an existing object as date (eg. 2015-12-03) and then assign the day part (03) to a variable. I want to change the number to "Thursday", depending on the real date format, not the actual date. And I want to do the same with the month format too.
$.getJSON("data/output.json", function (data2) {
$.each(data2.result, function(key, value){
var date = (JSON.stringify(data2.result[key].start_date));
day = date.slice(9, -1);
day.
data2.result[key].day=day;
/*month = date.slice(6, -4);
var monthstring = {"month": month};
data2.result[key].push(monthstring);*/
});
view2 = data2;
console.log(view2);
});