Skip to content

Instantly share code, notes, and snippets.

@bih
Created October 21, 2013 15:12
Show Gist options
  • Save bih/7085511 to your computer and use it in GitHub Desktop.
Save bih/7085511 to your computer and use it in GitHub Desktop.
Simple function in JavaScript to getMonthName() :-)
Date.prototype.getMonthName = function(){
return ["January", "February", "March", "April", "May", "June",
"July", "August", "September", "October", "November", "December"][this.getMonth()];
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment