Get Month Name In Javascript
Month Name in JavaScript. Get Month Name Javascript. Javascript Date Object, Months Names. There's a very simple way to get the month's name in javascript. The only problem is, that people do it over and over instead of just placing this in the Date object. Do, the solution is rather simple: Date.prototype.getMonthName = function () { var monthNames = [ "January" , "February" , "March" , "April" , "May" , "June" , "July" , "August" , "September" , "October" , "November" , "December" ]; return monthNames[ this .getMonth()]; } Next time you'll want to get a name you can just: var ...