I need to get the date format as \'DD-Mon-YYYY\' in javascript. I had asked a question, and it got marked duplicate to jQuery date formatting
But, the answers provi
var today = new Date(); var formattedtoday = today.getDate() + '-' + (today.getMonth() + 1) + '-' + today.getFullYear(); alert(formattedtoday);