I want to change the date for of data which is in format 2016-10-15
to d-m-yy
format in jquery as 15-10-2016
.I tried and console the output it shows 2016-10-15
.I caught this result in jquery ajax page which is fetched from database.
$.each(req,function(i,item){
var val=$.format.date(req[i].from_date, "dd/MMM/yyyy");
console.log(val); //'2016-10-15'
});