Created
May 7, 2013 12:29
-
-
Save EpokK/5532199 to your computer and use it in GitHub Desktop.
dateString
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Get date string for today's date (e.g. '2011-01-01') | |
function dateString () { | |
var d = new Date(Date.now() - 5*60*60*1000); | |
return d.getUTCFullYear() + '-' | |
+ (d.getUTCMonth() + 1) + '-' | |
+ d.getDate(); | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment