I am trying to get JavaScript to display tomorrows date in format (dd-mm-yyyy)
I have got this script which displays todays date in format (dd-mm-yyyy)
Date.prototype.NextDay = function (e) { return new Date(this.getFullYear(), this.getMonth(), this.getDate() + ("string" == typeof e ? parseInt(e, 10) : e)); } // tomorrow console.log(new Date().NextDay(1)) // day after tomorrow console.log(new Date().NextDay(2))